dwv 0.31.1 → 0.32.0-beta.0

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.
package/dist/dwv.min.js CHANGED
@@ -1,2 +1,2 @@
1
- /*! dwv 0.31.1 2023-04-27 19:37:50 */
2
- !function(e,t){"function"==typeof define&&define.amd?define(["jszip","konva","magic-wand-tool"],t):"object"==typeof module&&module.exports?module.exports=t(require("jszip"),require("konva/cmj"),require("magic-wand-tool")):e.dwv=t(e.JSZip,e.Konva,e.MagicWand)}(this,function(i,L,v){{{var e,l=void 0!==l?l:"undefined"!=typeof self?self:"undefined"!=typeof global?global:{},_=(void 0!==(e=L)&&void 0!==e.default&&(L=L.default),_||{}),_=(_.App=function(){var d=this,S=null,m=null,h=null,f=null,p=null,y=null,e=new _.gui.Style,n=new _.utils.ListenerHandler;function o(e){if(null===S.dataViewConfigs||void 0===S.dataViewConfigs)throw new Error("No available data view configuration");var t=[];return void 0!==S.dataViewConfigs["*"]?t=S.dataViewConfigs["*"]:void 0!==S.dataViewConfigs[e]&&(t=S.dataViewConfigs[e]),t}function a(e){for(var t=Object.keys(e),n=[],i=0;i<t.length;++i)for(var r=e[t[i]],o=0;o<r.length;++o){var a=r[o];if(!n.includes(a.divId)){var s=document.getElementById(a.divId),s=p.addLayerGroup(s),u=(l=u=void 0,s);u.addEventListener("zoomchange",D),u.addEventListener("offsetchange",D),u.addEventListener("renderstart",D),u.addEventListener("renderend",D);for(var l=0;l<_.image.viewEventNames.length;++l)u.addEventListener(_.image.viewEventNames[l],D);h&&h.hasTool("Draw")&&(u.addEventListener("drawcreate",D),u.addEventListener("drawdelete",D)),void 0!==a.orientation&&s.setTargetOrientation(_.math.getMatrixFromName(a.orientation)),n.push(a.divId)}}}function D(e){n.fireEvent(e)}function v(e){e.type="loadstart",D(e)}function C(e){e.type="loadprogress",D(e)}function T(e){void 0===e.data&&_.logger.error("Missing loaditem event data."),void 0===e.loadtype&&_.logger.error("Missing loaditem event load type.");var t,n=e.isfirstitem,i=null;"image"===e.loadtype?(n?m.addNew(e.loadid,e.data.image,e.data.info):m.update(e.loadid,e.data.image,e.data.info),i=e.data.info):"state"===e.loadtype&&((t=new _.io.State).apply(d,t.fromJSON(e.data)),i="state"),D({type:"loaditem",data:i,source:e.source,loadtype:e.loadtype,loadid:e.loadid,isfirstitem:e.isfirstitem}),"image"===e.loadtype&&0!==o(e.loadid).length&&n&&S.viewOnFirstLoadItem&&d.render(e.loadid)}function L(e){e.type="load",D(e)}function I(e){e.type="loadend",D(e)}function P(e){e.type="loaderror",D(e)}function w(e){e.type="loadabort",D(e)}function s(e,t){var n=m.get(e);if(!n)throw new Error("Cannot initialise layer with data id: "+e);var i=p.getLayerGroupByDivId(t.divId);if(!i)throw new Error("Cannot initialise layer with group id: "+t.divId);var r=n.image.getGeometry();p.unbindLayerGroups();var o,a=(new _.ViewFactory).create(n.meta,n.image),s=_.gui.getViewOrientation(r.getOrientation(),i.getTargetOrientation()),u=(a.setOrientation(s),"SEG"===n.image.getMeta().Modality&&a.setAlphaFunction(function(e){return 0===e[0]&&0===e[1]&&0===e[2]?0:255}),void 0!==t.colourMap&&a.setColourMap(t.colourMap),0===i.getNumberOfLayers()),l=1,c=(u||(l=.5,void 0===t.colourMap&&a.setColourMap(_.image.lut.rainbow)),i.addViewLayer()),a=(c.setView(a,e),r.getSize(s).get2D()),s=r.getSpacing(s).get2D(),l=(c.initialise(a,s,l),c.getViewController()),n=("SEG"===n.image.getMeta().Modality&&(l.addEventListener("masksegmentdelete",D),l.addEventListener("masksegmentredraw",D)),m.addEventListener("imageset",c.onimageset),m.addEventListener("imagechange",function(e){c.onimagechange(e),d.render(e.dataid)}),p.bindLayerGroups(),h&&h.bindLayer(c,i.getDivId()),h&&h.hasTool("Draw")&&((o=i.addDrawLayer()).initialise(a,s,e),o.setPlaneHelper(c.getViewController().getPlaneHelper())),[l.getCurrentIndex().getValues(),l.getCurrentPosition().getValues()]),a=(i.updateLayersToPositionChange({value:n,srclayerid:c.getId()}),p.syncLayerGroupScale(),r.getOrientation().getThirdColMajorDirection());c.setOffset(i.getOffset()),void 0!==t.orientation&&(2===a?"axial"!==t.orientation&&(c.addFlipOffsetY(),void 0!==o&&o.addFlipOffsetY()):0===a&&"sagittal"!==t.orientation&&(c.addFlipOffsetX(),void 0!==o&&o.addFlipOffsetX())),u?void 0!==t.orientation?0===a||2===a?i.flipScaleZ():(c.setScale(i.getScale()),void 0!==o&&o.setScale(i.getScale())):0===a?i.flipScaleZ():(c.setScale(i.getScale()),void 0!==o&&o.setScale(i.getScale())):(c.setScale(i.getScale()),void 0!==o&&o.setScale(i.getScale()))}this.getImage=function(e){return m.get(e).image},this.getLastImage=function(){return m.get(m.length()-1).image},this.setImage=function(e,t){m.setImage(e,t)},this.setLastImage=function(e){m.setImage(m.length()-1,e)},this.addNewImage=function(e,t){var n=m.length();return D({type:"loadstart",loadtype:"image",source:"internal",loadid:n}),m.addNew(n,e,t),D({type:"loaditem",loadtype:"image",data:t,source:"internal",loadid:n,isfirstitem:!0}),S.viewOnFirstLoadItem&&this.render(n),D({type:"load",loadtype:"image",source:"internal",loadid:n}),D({type:"loadend",loadtype:"image",source:"internal",loadid:n}),n},this.getMetaData=function(e){return m.get(e).meta},this.getNumberOfLoadedData=function(){return m.length()},this.canScroll=function(){return p.getActiveLayerGroup().getActiveViewLayer().getViewController().canScroll()},this.canWindowLevel=function(){return p.getActiveLayerGroup().getActiveViewLayer().getViewController().canWindowLevel()},this.getAddedScale=function(){return p.getActiveLayerGroup().getAddedScale()},this.getBaseScale=function(){return p.getActiveLayerGroup().getBaseScale()},this.getOffset=function(){return p.getActiveLayerGroup().getOffset()},this.getToolboxController=function(){return h},this.getActiveLayerGroup=function(){return p.getActiveLayerGroup()},this.getViewLayersByDataIndex=function(e){return p.getViewLayersByDataIndex(e)},this.getDrawLayersByDataIndex=function(e){return p.getDrawLayersByDataIndex(e)},this.getLayerGroupByDivId=function(e){return p.getLayerGroupByDivId(e)},this.getNumberOfLayerGroups=function(){return p.getNumberOfLayerGroups()},this.getStyle=function(){return e},this.addToUndoStack=function(e){null!==y&&y.add(e)},this.init=function(e){if(void 0===(S=e).viewOnFirstLoadItem&&(S.viewOnFirstLoadItem=!0),(y=new _.tool.UndoStack).addEventListener("undoadd",D),y.addEventListener("undo",D),y.addEventListener("redo",D),S.tools&&0!==S.tools.length){for(var t={},n=Object.keys(S.tools),i=0;i<n.length;++i){var r=n[i],o=S.tools[r];if(void 0!==_.tool[r]){if(t[r]=new _.tool[r](this),void 0!==t[r].addEventListener)for(var a=t[r].getEventNames(),s=0;s<a.length;++s)t[r].addEventListener(a[s],D);if(void 0!==o.options){var u="raw",l=(void 0!==t[r].getOptionsType&&(u=t[r].getOptionsType()),o.options);if("instance"===u||"factory"===u)for(var l={},c=0;c<o.options.length;++c){var d=o.options[c],g=d,x=("factory"===u&&(g+="Factory"),r.charAt(0).toLowerCase()+r.slice(1));void 0!==_.tool[x][g]?l[d]=_.tool[x][g]:_.logger.warn("Could not find option class for: "+d)}t[r].setOptions(l)}}else _.logger.warn("Could not initialise unknown tool: "+r)}h=new _.ctrl.ToolboxController(t)}(f=new _.ctrl.LoadController(S.defaultCharacterSet)).onloadstart=v,f.onprogress=C,f.onloaditem=T,f.onload=L,f.onloadend=I,f.onerror=P,f.onabort=w,m=new _.ctrl.DataController,p=new _.gui.Stage,void 0!==S.binders&&p.setBinders(S.binders)},this.getElement=function(e){return null},this.reset=function(){m.reset(),p.empty(),y&&((y=new _.tool.UndoStack).addEventListener("undoadd",D),y.addEventListener("undo",D),y.addEventListener("redo",D))},this.resetLayout=function(){p.reset(),p.draw()},this.addEventListener=function(e,t){n.add(e,t)},this.removeEventListener=function(e,t){n.remove(e,t)},this.loadFiles=function(e){0===e.length?_.logger.warn("Ignoring empty input file list."):f.loadFiles(e)},this.loadURLs=function(e,t){0===e.length?_.logger.warn("Ignoring empty input url list."):f.loadURLs(e,t)},this.loadImageObject=function(e){f.loadImageObject(e)},this.abortLoad=function(){f.abort()},this.fitToContainer=function(){p.syncLayerGroupScale()},this.initWLDisplay=function(){p.getActiveLayerGroup().getActiveViewLayer().getViewController().initialise()},this.getDataViewConfig=function(){return S.dataViewConfigs},this.setDataViewConfig=function(e){p.empty(),a(S.dataViewConfigs=e)},this.setLayerGroupsBinders=function(e){p.setBinders(e)},this.render=function(e){if(null==e)throw new Error("Cannot render without data index");0===p.getNumberOfLayerGroups()&&a(S.dataViewConfigs);var t=o(e);if(0===t.length)_.logger.info("Not rendering data: "+e+" (no data view config)");else for(var n=0;n<t.length;++n){var i=t[n],r=p.getLayerGroupByDivId(i.divId);if(!r)throw new Error("No layer group for "+i.divId);0===r.getViewLayersByDataIndex(e).length&&(0===r.getNumberOfLayers()?(s(e,i),h&&h.init()):s(e,i)),r.draw()}},this.zoom=function(e,t,n){var i=p.getActiveLayerGroup(),r=i.getActiveViewLayer().getViewController().getCurrentScrollPosition(),t=new _.math.Point3D(t,n,r);i.addScale(e,t),i.draw()},this.translate=function(e,t){var n=p.getActiveLayerGroup();n.addTranslation({x:e,y:t}),n.draw()},this.setOpacity=function(e){var t=p.getActiveLayerGroup().getActiveViewLayer();t.setOpacity(e),t.draw()},this.setDrawings=function(e,t){var n=p.getActiveLayerGroup(),i=n.getActiveViewLayer().getViewController(),n=n.getActiveDrawLayer().getDrawController();n.setDrawings(e,t,D,this.addToUndoStack),n.activateDrawLayer(i.getCurrentOrientedIndex(),i.getScrollIndex())},this.getState=function(){return(new _.io.State).toJSON(d)},this.onResize=function(e){d.fitToContainer()},this.onKeydown=function(e){D(e)},this.defaultOnKeydown=function(e){if(e.ctrlKey)if(e.shiftKey){var t=p.getActiveLayerGroup().getActiveViewLayer().getViewController(),n=t.getImageSize();"ArrowLeft"===e.key?n.moreThanOne(3)&&t.decrementIndex(3):"ArrowUp"===e.key?t.canScroll()&&t.incrementScrollIndex():"ArrowRight"===e.key?n.moreThanOne(3)&&t.incrementIndex(3):"ArrowDown"===e.key&&t.canScroll()&&t.decrementScrollIndex()}else if("y"===e.key)y.redo();else if("z"===e.key)y.undo();else if(" "===e.key)for(var i=0;i<p.getNumberOfLayerGroups();++i)p.getLayerGroup(i).setShowCrosshair(!p.getLayerGroup(i).getShowCrosshair())},this.resetDisplay=function(){d.resetLayout(),d.initWLDisplay()},this.resetZoom=function(){d.resetLayout()},this.setColourMap=function(e){p.getActiveLayerGroup().getActiveViewLayer().getViewController().setColourMapFromName(e)},this.setWindowLevelPreset=function(e){p.getActiveLayerGroup().getActiveViewLayer().getViewController().setWindowLevelPreset(e)},this.setTool=function(e){for(var t=0;t<p.getNumberOfLayerGroups();++t){var n=p.getLayerGroup(t),i=null;(i="Draw"===e||"Livewire"===e||"Floodfill"===e?n.getActiveDrawLayer():n.getActiveViewLayer())&&h.bindLayer(i,n.getDivId())}h.setSelectedTool(e)},this.setToolFeatures=function(e){h.setToolFeatures(e)},this.undo=function(){y.undo()},this.redo=function(){y.redo()},this.getStackSize=function(){return y.getStackSize()},this.getCurrentStackIndex=function(){return y.getCurrentStackIndex()}},_||{}),_=(_.ctrl=_.ctrl||{},_.ctrl.DataController=function(){var i={},n=new _.utils.ListenerHandler;function r(e){n.fireEvent(e)}function o(t){return function(e){e.dataid=t,r(e)}}function a(e){return void 0!==e.x00020010?new _.dicom.DicomElementsWrapper(e).dumpToObject():e}this.length=function(){return Object.keys(i).length},this.reset=function(){i=[]},this.get=function(e){return i[e]},this.setImage=function(e,t){r({type:"imageset",value:[i[e].image=t],dataid:e}),t.addEventListener("imagechange",o(e))},this.addNew=function(e,t,n){if(void 0!==i[e])throw new Error("Index already used in storage: "+e);i[e]={image:t,meta:a(n)},t.addEventListener("imagechange",o(e))},this.update=function(e,t,n){e=i[e],e.image.appendSlice(t),t="",t=void 0!==n.x00020010?"InstanceNumber":"imageUid";e.meta=_.utils.mergeObjects(e.meta,a(n),t,"value")},this.addEventListener=function(e,t){n.add(e,t)},this.removeEventListener=function(e,t){n.remove(e,t)}},_||{}),L=(_.draw=_.draw||{},_.ctrl=_.ctrl||{},L||{}),_=(_.draw.getDrawPositionGroupId=function(e){return"slice-"+e.get(2)+"_frame-"+(4===e.length()?e.get(3):0)},_.draw.getPositionFromGroupId=function(e){var t=e.indexOf("_");return-1===t&&_.logger.warn("Badly formed PositionGroupId: "+e),{sliceNumber:e.substring(6,t),frameNumber:e.substring(t+7)}},_.draw.isNodeNameShape=function(e){return"shape"===e.name()},_.draw.isNodeNameShapeExtra=function(e){return e.name().startsWith("shape-")},_.draw.isNodeNameLabel=function(e){return"label"===e.name()},_.draw.isPositionNode=function(e){return"position-group"===e.name()},_.draw.isNodeWithId=function(t){return function(e){return e.id()===t}},_.draw.canNodeChangeColour=function(e){return"anchor"!==e.name()&&"label"!==e.name()},_.draw.getHierarchyLog=function(e,t){void 0===t&&(t="");for(var n=e.getChildren(),i=t+"|__ "+e.name()+": "+e.id()+"\n",r=0;r<n.length;++r)i+=_.draw.getHierarchyLog(n[r],t+" ");return i},_.ctrl.DrawController=function(m){var u=null;this.getCurrentPosGroup=function(){var e=m.getChildren(function(e){return e.id()===u}),t=null;return 1===e.length?t=e[0]:0===e.length?((t=new L.Group).name("position-group"),t.id(u),t.visible(!0),m.add(t)):_.logger.warn("Unexpected number of draw position groups."),t},this.reset=function(){m=null},this.getGroup=function(e){var t=m.findOne("#"+e);return void 0===t&&_.logger.warn("Cannot find node with id: "+e),t},this.activateDrawLayer=function(e,t){for(var n=[t],i=3;i<e.length();++i)n.push(i);u=e.toStringId(n);for(var r,o=m.getChildren(_.draw.isPositionNode),a=0,s=o.length;a<s;++a)r=!1,o[a].id()===u&&(r=!0),o[a].visible(r);m.draw()},this.getDrawDisplayDetails=function(){for(var e=[],t=m.getChildren(),n=0,i=t.length;n<i;++n)for(var r=_.math.getIndexFromStringId(t[n].id()),o=t[n].getChildren(),a=0,s=o.length;a<s;++a){var u,l=o[a].getChildren(_.draw.isNodeNameShape)[0],c=o[a].getChildren(_.draw.isNodeNameLabel)[0].getChildren()[0],d=l.className;"Line"===d&&(u=o[a].getChildren(_.draw.isNodeNameShapeExtra),l.closed()?d="Roi":0!==u.length&&(d=-1!==(u=u[0].name()).indexOf("triangle")?"Arrow":-1!==u.indexOf("arc")?"Protractor":"Ruler")),"Rect"===d&&(d="Rectangle"),e.push({id:o[a].id(),position:r.toString(),type:d,color:l.stroke(),meta:c.meta})}return e},this.getDrawStoreDetails=function(){for(var e={},t=m.getChildren(_.draw.isPositionNode),n=0,i=t.length;n<i;++n)for(var r,o=0,a=(r=t[n].getChildren()).length;o<a;++o){for(var s,u=(s=r[o]).find(".anchor"),l=0;l<u.length;++l)u[l].remove();var c=s.find(".text");1!==c.length&&_.logger.warn("There should not be more than one text per shape."),e[s.id()]={meta:c[0].meta}}return e},this.setDrawings=function(e,t,n,i){for(var r=L.Node.create(e).getChildren(_.draw.isPositionNode),o=0,a=r.length;o<a;++o)for(var s=r[o],u=m.getChildren(_.draw.isNodeWithId(s.id()))[0],l=(void 0===u&&(u=new L.Group({id:s.id(),name:"position-group",visible:!1}),m.add(u)),s.getChildren()),c=0,d=l.length;c<d;++c){var g,x=l[0],S=(u.add(x),x.getChildren(_.draw.isNodeNameShape)[0]),S=new _.tool.DrawGroupCommand(x,S.className,m);S.onExecute=n,S.onUndo=n,t&&(g=t[x.id()],(x=x.getChildren(_.draw.isNodeNameLabel)[0].getText()).meta=g.meta,x.setText(_.utils.replaceFlags(x.meta.textExpr,x.meta.quantification))),S.execute(),i(S)}},this.updateDraw=function(e){var t=m.findOne("#"+e.id);if(void 0===t)_.logger.warn("[updateDraw] Cannot find group with id: "+e.id);else{for(var n=t.getChildren(_.draw.isNodeNameShape),i=0;i<n.length;++i)n[i].stroke(e.color);for(var r=t.getChildren(_.draw.isNodeNameShapeExtra),o=0;o<r.length;++o)void 0!==r[o].stroke()?r[o].stroke(e.color):void 0!==r[o].fill()&&r[o].fill(e.color);for(var a,s=t.getChildren(_.draw.isNodeNameLabel)[0],u=_.utils.getShadowColour(e.color),l=s.getChildren(),c=0;c<l.length;++c)l[c].fill(e.color),"Text"===l[c].className&&((a=l[c]).shadowColor(u),void 0!==e.meta&&(a.meta=e.meta,a.setText(_.utils.replaceFlags(a.meta.textExpr,a.meta.quantification)),s.setVisible(0!==a.meta.textExpr.length)));m.draw()}},this.deleteDrawGroup=function(e,t,n){var i=e.getChildren(_.draw.isNodeNameShape)[0],i=_.tool.GetShapeDisplayName(i),e=new _.tool.DeleteGroupCommand(e,i,m);e.onExecute=t,e.onUndo=t,e.execute(),n(e)},this.deleteDraw=function(e,t,n){e=this.getGroup(e);return void 0!==e&&(this.deleteDrawGroup(e,t,n),!0)},this.deleteDraws=function(e,t){for(var n=m.getChildren();n.length;)this.deleteDrawGroup(n[0],e,t)}},_||{}),_=(_.ctrl=_.ctrl||{},_.ctrl.LoadController=function(o){var a=this,s={},u=-1;function l(e,t,n,i){var r={loadtype:n},o=++u;r.loadid=o,t.onloadstart=function(e){s[o]={loader:t,isFirstItem:!0},c(a.onloadstart,r)(e)},t.onprogress=c(a.onprogress,r),t.onloaditem=function(e){var t={loadtype:n,loadid:o};void 0!==s[o]&&(t.isfirstitem=s[o].isFirstItem),c(a.onloaditem,t)(e),void 0!==s[o]&&s[o].isFirstItem&&(s[o].isFirstItem=!1)},t.onload=c(a.onload,r),t.onloadend=function(e){delete s[o],c(a.onloadend,r)(e)},t.onerror=c(a.onerror,r),t.onabort=c(a.onabort,r);try{t.load(e,i)}catch(e){return a.onerror({error:e,loadid:o}),void a.onloadend({loadid:o})}}function c(r,o){return function(e){for(var t=Object.keys(o),n=0;n<t.length;++n){var i=t[n];e[i]=o[i]}r(e)}}this.loadFiles=function(e){var t,n;"json"===e[0].name.split(".").pop().toLowerCase()?(t=e[0],n=new _.io.FilesLoader,l([t],n,"state")):(t=e,(n=new _.io.FilesLoader).setDefaultCharacterSet(o),l(t,n,"image"))},this.loadURLs=function(e,t){var n,i,r;"json"===e[0].split(".").pop().toLowerCase()?(n=e[0],i=t,r=new _.io.UrlsLoader,l([n],r,"state",i)):(n=e,r=t,(i=new _.io.UrlsLoader).setDefaultCharacterSet(o),l(n,i,"image",r))},this.loadImageObject=function(e){l(e,new _.io.MemoryLoader,"image")},this.abort=function(){for(var e=Object.keys(s),t=0;t<e.length;++t)s[t].loader.abort(),delete s[t]}},_.ctrl.LoadController.prototype.onloadstart=function(e){},_.ctrl.LoadController.prototype.onprogress=function(e){},_.ctrl.LoadController.prototype.onload=function(e){},_.ctrl.LoadController.prototype.onloadend=function(e){},_.ctrl.LoadController.prototype.onerror=function(e){},_.ctrl.LoadController.prototype.onabort=function(e){},_||{}),_=(_.ctrl=_.ctrl||{},_.ctrl.ToolboxController=function(t){var n=null,r=[],s={};function u(e,t){function i(e){var t;n&&(t=n[e.type])&&t(e)}return void 0===r[e]&&(r[e]=[]),void 0===r[e][t]&&(r[e][t]="keydown"===t?function(e){i(e)}:"touchend"===t?function(e){i(e)}:function(e){var t,n;t=e,n=_.gui.getEventOffset(t),t._x=n[0].x,t._y=n[0].y,2===n.length&&(t._x1=n[1].x,t._y1=n[1].y),i(e)}),r[e][t]}this.init=function(){for(var e in t)t[e].init();l.addEventListener("keydown",u("window","keydown"),!0)},this.getToolList=function(){return t},this.hasTool=function(e){return void 0!==this.getToolList()[e]},this.getSelectedTool=function(){return n},this.getSelectedToolEventHandler=function(e){return this.getSelectedTool()[e]},this.setSelectedTool=function(e){if(!this.hasTool(e))throw new Error("Unknown tool: '"+e+"'");n&&n.activate(!1),(n=t[e]).activate(!0)},this.setToolFeatures=function(e){this.getSelectedTool()&&this.getSelectedTool().setFeatures(e)},this.bindLayer=function(e,t){if(void 0!==s[t]){var n=s[t];n.unbindInteraction();for(var i=_.gui.interactionEventNames,r=0;r<i.length;++r)n.removeEventListener(i[r],u(n.getId(),i[r]))}e.bindInteraction();for(var o=_.gui.interactionEventNames,a=0;a<o.length;++a)e.addEventListener(o[a],u(e.getId(),o[a]));s[t]=e}},_||{}),_=(_.ctrl=_.ctrl||{},_.ctrl.ViewController=function(l,e){var i=this,r=null,n=e;if(void 0===l.getImage())throw new Error("View does not have an image, cannot setup controller");var o,a=new _.image.PlaneHelper(l.getImage().getGeometry().getRealSpacing(),l.getImage().getGeometry().getOrientation(),l.getOrientation()),s=("SEG"===l.getImage().getMeta().Modality&&(o=new _.image.MaskSegmentHelper(l.getImage())),new _.utils.ListenerHandler);function u(e){e.dataid=n,s.fireEvent(e)}this.getPlaneHelper=function(){return a},this.isMask=function(){return void 0!==o},this.getMaskSegmentHelper=function(){return o},this.applyHiddenSegments=function(){this.isMask&&this.setViewAlphaFunction(o.getAlphaFunc())},this.deleteSegment=function(e,t){this.isMask&&o.deleteSegment(e,u,t)},this.initialise=function(){this.setWindowLevelPresetById(0),this.setCurrentPosition(this.getPositionFromPlanePoint(0,0))},this.getWindowLevelPresetsNames=function(){return l.getWindowPresetsNames()},this.addWindowLevelPresets=function(e){return l.addWindowPresets(e)},this.setWindowLevelPreset=function(e){l.setWindowLevelPreset(e)},this.setWindowLevelPresetById=function(e){l.setWindowLevelPresetById(e)},this.isPlaying=function(){return null!==r},this.getCurrentPosition=function(){return l.getCurrentPosition()},this.getCurrentIndex=function(){return l.getCurrentIndex()},this.getCurrentOrientedIndex=function(){var e,t=l.getCurrentIndex();return void 0!==l.getOrientation()&&(e=a.getImageDeOrientedVector3D(new _.math.Vector3D(t.get(0),t.get(1),t.get(2))),t=new _.math.Index([e.getX(),e.getY(),e.getZ()])),t},this.getScrollIndex=function(){return l.getScrollIndex()},this.getCurrentScrollIndexValue=function(){return l.getCurrentIndex().get(l.getScrollIndex())},this.getOrigin=function(e){return l.getOrigin(e)},this.getCurrentScrollPosition=function(){var e=l.getScrollIndex();return l.getCurrentPosition().get(e)},this.generateImageData=function(e,t){l.generateImageData(e,t)},this.setImage=function(e,t){l.setImage(e),n=t},this.get2DSpacing=function(){var e=l.getImage().getGeometry().getSpacing();return[e.get(0),e.get(1)]},this.getRescaledImageValue=function(e){var t,n,i=l.getImage();if(i.canQuantify())return t=i.getGeometry(),e=t.worldToIndex(e),t.isIndexInBounds(e)?i.getRescaledValueAtIndex(e):n},this.getPixelUnit=function(){return l.getImage().getMeta().pixelUnit},this.getImageRegionValues=function(e,t){var n,i,r=l.getImage(),o=l.getOrientation(),a=this.getCurrentIndex(),s=!0,u=(_.math.isIdentityMat33(o)||(n=_.image.getSliceIterator(r,a,s,o),n=_.image.getIteratorValues(n),(u=r.getGeometry().getSize(o).getValues())[2]=1,u=new _.image.Size(u),(o=r.getGeometry().getSpacing(o).getValues())[2]=1,o=new _.image.Spacing(o),i=new _.math.Point3D(0,0,0),i=new _.image.Geometry(i,u,o),r=new _.image.Image(i,n),a=new _.math.Index([0,0,0]),s=!1),_.image.getRegionSliceIterator(r,a,s,e,t)),o=[];return o=u?_.image.getIteratorValues(u):o},this.getImageVariableRegionValues=function(e){var e=_.image.getVariableRegionSliceIterator(l.getImage(),this.getCurrentIndex(),!0,e),t=[];return t=e?_.image.getIteratorValues(e):t},this.canQuantifyImage=function(){return l.getImage().canQuantify()},this.canWindowLevel=function(){return l.getImage().canWindowLevel()},this.canScroll=function(){return l.getImage().canScroll(l.getOrientation())},this.getImageSize=function(){return l.getImage().getGeometry().getSize(l.getOrientation())},this.getImageWorldSize=function(){var e=l.getImage().getGeometry(),t=e.getSize(l.getOrientation()).get2D(),e=e.getSpacing(l.getOrientation()).get2D();return{x:t.x*e.x,y:t.y*e.y}},this.getImageRescaledDataRange=function(){return l.getImage().getRescaledDataRange()},this.equalImageMeta=function(e){for(var t=l.getImage().getMeta(),n=Object.keys(e),i=0;i<n.length;++i){var r=n[i];if(void 0===t[r])return!1;if(t[r]!==e[r])return!1}return!0},this.canSetPosition=function(e){return l.canSetPosition(e)},this.setCurrentPosition=function(e,t){return l.setCurrentPosition(e,t)},this.getPositionFromPlanePoint=function(e,t){var n=this.getCurrentScrollIndexValue(),e=new _.math.Point3D(e,t,n),t=a.getImageOrientedVector3D(e),n=l.getImage().getGeometry().pointToWorld(t);return this.getCurrentPosition().mergeWith3D(n)},this.getPlanePositionFromPosition=function(e){e=l.getImage().getGeometry().worldToPoint(e),e=a.getImageDeOrientedVector3D(e);return{x:e.getX(),y:e.getY()}},this.setCurrentIndex=function(e,t){return l.setCurrentIndex(e,t)},this.getPlanePositionFromPlanePoint=function(e){var t=this.getCurrentScrollIndexValue(),e=new _.math.Point3D(e.x,e.y,t),t=a.getTargetDeOrientedVector3D(e),e=l.getImage().getGeometry().getRealSpacing();return new _.math.Point3D(t.getX()*e.get(0),t.getY()*e.get(1),t.getZ()*e.get(2))},this.getOffset3DFromPlaneOffset=function(e){return a.getOffset3DFromPlaneOffset(e)},this.incrementIndex=function(e,t){return l.incrementIndex(e,t)},this.decrementIndex=function(e,t){return l.decrementIndex(e,t)},this.decrementScrollIndex=function(e){return l.decrementScrollIndex(e)},this.incrementScrollIndex=function(e){return l.incrementScrollIndex(e)},this.play=function(){var e,t,n;this.canScroll()&&(null===r?(t=(e=l.getImage()).getMeta().RecommendedDisplayFrameRate,t=l.getPlaybackMilliseconds(t),n=e.getGeometry().getSize().canScroll3D(),r=setInterval(function(){var e,t;(n?i.incrementScrollIndex():i.incrementIndex(3))||(t=i.getCurrentIndex().getValues(),e=l.getOrientation(),n?t[e.getThirdColMajorDirection()]=0:t[3]=0,e=new _.math.Index(t),t=l.getImage().getGeometry(),i.setCurrentPosition(t.indexToWorld(e)))},t)):this.stop())},this.stop=function(){null!==r&&(clearInterval(r),r=null)},this.getWindowLevel=function(){return{width:l.getCurrentWindowLut().getWindowLevel().getWidth(),center:l.getCurrentWindowLut().getWindowLevel().getCenter()}},this.setWindowLevel=function(e,t){l.setWindowLevel(e,t)},this.getColourMap=function(){return l.getColourMap()},this.setColourMap=function(e){l.setColourMap(e)},this.setViewAlphaFunction=function(e){l.setAlphaFunction(e)},this.setColourMapFromName=function(e){if(!_.tool.colourMaps[e])throw new Error("Unknown colour map: '"+e+"'");this.setColourMap(_.tool.colourMaps[e])},this.addEventListener=function(e,t){s.add(e,t)},this.removeEventListener=function(e,t){s.remove(e,t)}},_||{}),_=(_.dicom=_.dicom||{},_.dicom.isNativeLittleEndian=function(){return 0<new Int8Array(new Int16Array([1]).buffer)[0]},_.dicom.flipArrayEndianness=function(e){for(var t,n=e.byteLength,i=new Uint8Array(e.buffer,e.byteOffset,n),r=e.BYTES_PER_ELEMENT,o=0;o<n;o+=r)for(var a=o+r-1,s=o;s<a;a--,s++)t=i[s],i[s]=i[a],i[a]=t},_.dicom.DataReader=function(u,t){void 0===t&&(t=!0);var e=_.dicom.isNativeLittleEndian(),a=t!==e,n=new DataView(u);this.readUint16=function(e){return n.getUint16(e,t)},this.readInt16=function(e){return n.getInt16(e,t)},this.readUint32=function(e){return n.getUint32(e,t)},this.readBigUint64=function(e){return n.getBigUint64(e,t)},this.readInt32=function(e){return n.getInt32(e,t)},this.readBigInt64=function(e){return n.getBigInt64(e,t)},this.readFloat32=function(e){return n.getFloat32(e,t)},this.readFloat64=function(e){return n.getFloat64(e,t)},this.readBinaryArray=function(e,t){for(var n,i,r=new Uint8Array(u,e,t),o=8*r.length,a=new Uint8Array(o),s=0;s<o;++s)n=s%8,i=Math.floor(s/8),a[s]=255*(0!=(r[i]&1<<n));return a},this.readUint8Array=function(e,t){return new Uint8Array(u,e,t)},this.readInt8Array=function(e,t){return new Int8Array(u,e,t)},this.readUint16Array=function(e,t){var n=Uint16Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new Uint16Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new Uint16Array(i),o=0;o<i;++o)r[o]=this.readUint16(e+n*o);return r},this.readInt16Array=function(e,t){var n=Int16Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new Int16Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new Int16Array(i),o=0;o<i;++o)r[o]=this.readInt16(e+n*o);return r},this.readUint32Array=function(e,t){var n=Uint32Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new Uint32Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new Uint32Array(i),o=0;o<i;++o)r[o]=this.readUint32(e+n*o);return r},this.readUint64Array=function(e,t){var n=BigUint64Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new BigUint64Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new BigUint64Array(i),o=0;o<i;++o)r[o]=this.readBigUint64(e+n*o);return r},this.readInt32Array=function(e,t){var n=Int32Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new Int32Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new Int32Array(i),o=0;o<i;++o)r[o]=this.readInt32(e+n*o);return r},this.readInt64Array=function(e,t){var n=BigInt64Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new BigInt64Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new BigInt64Array(i),o=0;o<i;++o)r[o]=this.readBigInt64(e+n*o);return r},this.readFloat32Array=function(e,t){var n=Float32Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new Float32Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new Float32Array(i),o=0;o<i;++o)r[o]=this.readFloat32(e+n*o);return r},this.readFloat64Array=function(e,t){var n=Float64Array.BYTES_PER_ELEMENT,i=t/n,r=null;if(e%n==0)r=new Float64Array(u,e,i),a&&_.dicom.flipArrayEndianness(r);else for(var r=new Float64Array(i),o=0;o<i;++o)r[o]=this.readFloat64(e+n*o);return r}},_.dicom.DataReader.prototype.readHex=function(e){e=this.readUint16(e).toString(16);return"0x0000".substring(0,6-e.length)+e.toUpperCase()},_||{}),_=(_.dicom=_.dicom||{},_.dicom.DataWriter=function(e,n){void 0===n&&(n=!0);var i=new DataView(e);this.useUnVrForPrivateSq=!1,this.writeUint8=function(e,t){return i.setUint8(e,t),e+Uint8Array.BYTES_PER_ELEMENT},this.writeInt8=function(e,t){return i.setInt8(e,t),e+Int8Array.BYTES_PER_ELEMENT},this.writeUint16=function(e,t){return i.setUint16(e,t,n),e+Uint16Array.BYTES_PER_ELEMENT},this.writeInt16=function(e,t){return i.setInt16(e,t,n),e+Int16Array.BYTES_PER_ELEMENT},this.writeUint32=function(e,t){return i.setUint32(e,t,n),e+Uint32Array.BYTES_PER_ELEMENT},this.writeUint64=function(e,t){return i.setBigUint64(e,t,n),e+BigUint64Array.BYTES_PER_ELEMENT},this.writeInt32=function(e,t){return i.setInt32(e,t,n),e+Int32Array.BYTES_PER_ELEMENT},this.writeInt64=function(e,t){return i.setBigInt64(e,t,n),e+BigInt64Array.BYTES_PER_ELEMENT},this.writeFloat32=function(e,t){return i.setFloat32(e,t,n),e+Float32Array.BYTES_PER_ELEMENT},this.writeFloat64=function(e,t){return i.setFloat64(e,t,n),e+Float64Array.BYTES_PER_ELEMENT},this.writeHex=function(e,t){t=parseInt(t.substring(2),16);return i.setUint16(e,t,n),e+Uint16Array.BYTES_PER_ELEMENT}},_.dicom.DataWriter.prototype.writeBinaryArray=function(e,t){if(t.length%8!=0)throw new Error("Cannot write boolean array as binary.");for(var n=null,i=0,r=t.length;i<r;i+=8){for(var n=0,o=0;o<8;++o)n+=(0===t[i+o]?0:1)<<o;e=this.writeUint8(e,n)}return e},_.dicom.DataWriter.prototype.writeUint8Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeUint8(e,t[n]);return e},_.dicom.DataWriter.prototype.writeInt8Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeInt8(e,t[n]);return e},_.dicom.DataWriter.prototype.writeUint16Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeUint16(e,t[n]);return e},_.dicom.DataWriter.prototype.writeInt16Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeInt16(e,t[n]);return e},_.dicom.DataWriter.prototype.writeUint32Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeUint32(e,t[n]);return e},_.dicom.DataWriter.prototype.writeUint64Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeUint64(e,t[n]);return e},_.dicom.DataWriter.prototype.writeInt32Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeInt32(e,t[n]);return e},_.dicom.DataWriter.prototype.writeInt64Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeInt64(e,t[n]);return e},_.dicom.DataWriter.prototype.writeFloat32Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeFloat32(e,t[n]);return e},_.dicom.DataWriter.prototype.writeFloat64Array=function(e,t){for(var n=0,i=t.length;n<i;++n)e=this.writeFloat64(e,t[n]);return e},_||{}),_=(_.dicom=_.dicom||{},_.dicom.DicomElementsWrapper=function(s){this.getDEFromKey=function(e){return s[e]},this.getFromKey=function(e,t){void 0===t&&(t=!1);var n=null,e=s[e];return n=void 0!==e?1===e.value.length&&!1===t?e.value[0]:e.value:n},this.dumpToObject=function(){for(var e,t=Object.keys(s),n={},i=0,r=t.length;i<r;++i)e=s[t[i]],n[this.getTagName(e.tag)]=this.getElementAsObject(e);return n},this.getTagName=function(e){var t=e.getNameFromDictionary();return t=null===t?e.getKey2():t},this.getElementAsObject=function(e){var t=null,n=_.dicom.isPixelDataTag(e.tag),i=e.vr;if("SQ"!==i||void 0===e.value||n)t=this.getElementValueAsString(e);else for(var t=[],r=e.value,o=null,a=0;a<r.length;++a){for(var o={},s=Object.keys(r[a]),u=0;u<s.length;++u){var l=r[a][s[u]],c=this.getTagName(l.tag);"Item"!==c&&(o[c]=this.getElementAsObject(l))}t.push(o)}return{value:t,group:e.tag.getGroup(),element:e.tag.getElement(),vr:i,vl:e.vl}},this.dump=function(){for(var e=Object.keys(s),t=(o=(o=(o="\n")+"# Dicom-File-Format\n"+"\n")+"# Dicom-Meta-Information-Header\n"+"# Used TransferSyntax: ",_.dicom.isNativeLittleEndian()?o+="Little Endian Explicit\n":o+="NOT Little Endian Explicit\n",null),n=!0,i=0,r=e.length;i<r;++i){var o,a,t=s[e[i]];n&&"0x0002"!==t.tag.getGroup()&&(o+="\n# Dicom-Data-Set\n# Used TransferSyntax: ",a=_.dicom.cleanString(s.x00020010.value[0]),o=o+_.dicom.getTransferSyntaxName(a)+"\n",n=!1),o+=this.getElementAsString(t)+"\n"}return o}},_.dicom.DicomElementsWrapper.prototype.getElementValueAsString=function(e,t){var n="";if(void 0===t&&(t=!0),null==e)return n;var i=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e};if("SQ"!==e.vr&&1===e.value.length&&""===e.value[0])n+="(no value available)";else if(_.dicom.isPixelDataTag(e.tag)&&e.undefinedLength)n="(PixelSequence)";else if("DA"===e.vr&&t){var r=e.value[0],o=4,a=6;8!==r.length&&(o=5,a=8);n=new Date(parseInt(r.substring(0,4),10),parseInt(r.substring(o,o+2),10)-1,parseInt(r.substring(a,a+2),10)).toLocaleDateString()}else if("TM"===e.vr&&t){o=e.value[0];n=o.substring(0,2)+":"+(4<=o.length?o.substring(2,4):"00")+":"+(6<=o.length?o.substring(4,6):"00")}else for(var s=!1,u=(0!==e.vr.length&&(s="O"===e.vr[0].toUpperCase()),"FL"===e.vr||"FD"===e.vr||"DS"===e.vr),l="",c=0,d=e.value.length;c<d;++c){var g,l="";if(0!==c&&(l+="\\"),u?("string"==typeof(g=e.value[c])&&(g=_.dicom.cleanString(g)),!i(g=Number(g))&&t?l+=g.toPrecision(4):l+=g.toString()):s?(g=e.value[c].toString(16),l+=g="OB"===e.vr?"00".substring(0,2-g.length)+g:"0000".substring(0,4-g.length)+g):"string"==typeof e.value[c]?l+=_.dicom.cleanString(e.value[c]):l+=e.value[c],!(n.length+l.length<=65)){n+="...";break}n+=l}return n},_.dicom.DicomElementsWrapper.prototype.getElementValueAsStringFromKey=function(e){return this.getElementValueAsString(this.getDEFromKey(e))},_.dicom.DicomElementsWrapper.prototype.getElementAsString=function(e,t){t=t||"";var n=e.tag.getNameFromDictionary(),i=e.value.length,r=!1,o=(0!==e.vr.length&&(r="O"===e.vr[0].toUpperCase()),_.dicom.isItemDelimitationItemTag(e.tag)||_.dicom.isSequenceDelimitationItemTag(e.tag)?i=0:r&&(i=1),_.dicom.isPixelDataTag(e.tag)&&e.undefinedLength),a=null,s=(a=(a=(a=(a="(")+e.tag.getGroup().substring(2).toLowerCase()+",")+e.tag.getElement().substring(2).toLowerCase())+") "+e.vr,"SQ"!==e.vr&&1===e.value.length&&""===e.value[0]?(a+=" (no value available)",i=0):"na"===e.vr?a=a+" "+e.value[0]:o?a+=" (PixelSequence #="+i+")":a="SQ"===e.vr?(a+=" (Sequence with",e.undefinedLength?a+=" undefined":a+=" explicit",(a+=" length #=")+e.value.length+")"):r||"pi"===e.vr||"UL"===e.vr||"US"===e.vr||"SL"===e.vr||"SS"===e.vr||"FL"===e.vr||"FD"===e.vr||"AT"===e.vr?(a+=" ")+this.getElementValueAsString(e,!1):(a+=" [")+this.getElementValueAsString(e,!1)+"]",55-a.length);if(0<s)for(var u=0;u<s;++u)a+=" ";a+=" # ",e.vl<100&&(a+=" "),e.vl<10&&(a+=" "),a=(a=(a+=e.vl)+", "+i)+" "+(null!==n?n:"Unknown Tag & Data");var l=null;if("SQ"===e.vr){for(var c=0,d=e.value.length;c<d;++c){var g=e.value[c],x=Object.keys(g);if(0!==x.length){var S=g.xFFFEE000,l="(Item with";S.undefinedLength?l+=" undefined":l+=" explicit",l+=" length #="+(x.length-1)+")",S.value=[l],S.vr="na";for(var a=(a+="\n")+this.getElementAsString(S,t+" "),m=0,h=x.length;m<h;++m)"xFFFEE000"!==x[m]&&(a=(a+="\n")+this.getElementAsString(g[x[m]],t+" "));l="(ItemDelimitationItem",S.undefinedLength||(l+=" for re-encoding"),l+=")";S={tag:_.dicom.getItemDelimitationItemTag(),vr:"na",vl:"0",value:[l]};a=(a+="\n")+this.getElementAsString(S,t+" ")}}l="(SequenceDelimitationItem",e.undefinedLength||(l+=" for re-encod."),l+=")";r={tag:_.dicom.getSequenceDelimitationItemTag(),vr:"na",vl:"0",value:[l]};a=(a+="\n")+this.getElementAsString(r,t)}else if(o){for(var f=null,p=0,y=e.value.length;p<y;++p)a+="\n",(f=e.value[p]).vr="pi",a+=this.getElementAsString(f,t+" ");i={tag:_.dicom.getSequenceDelimitationItemTag(),vr:"na",vl:"0",value:["(SequenceDelimitationItem)"]};a=(a+="\n")+this.getElementAsString(i,t)}return t+a},_.dicom.DicomElementsWrapper.prototype.getFromGroupElement=function(e,t){return this.getFromKey(new _.dicom.Tag(e,t).getKey())},_.dicom.DicomElementsWrapper.prototype.getFromName=function(e){var t=null,e=_.dicom.getTagFromDictionary(e);return t=null!==e?this.getFromKey(e.getKey()):t},_.dicom.DicomElementsWrapper.prototype.getImageSize=function(){var e=this.getFromKey("x00280010");if(!e)throw new Error("Missing or empty DICOM image number of rows");var t=this.getFromKey("x00280011");if(t)return new _.image.Size([t,e,1]);throw new Error("Missing or empty DICOM image number of columns")},_.dicom.DicomElementsWrapper.prototype.getPixelSpacing=function(){for(var e=1,t=1,n=["x00280030","x00181164","x00182010","x00280034"],i=0;i<n.length;++i){var r=this.getFromKey(n[i],!0);if(r&&2===r.length){e=parseFloat(r[0]),t=parseFloat(r[1]);break}}return 0===t&&(_.logger.warn("Zero column spacing."),t=1),0===e&&(_.logger.warn("Zero row spacing."),e=1),new _.image.Spacing([t,e,1])},_.dicom.DicomElementsWrapper.prototype.getTime=function(){},_.dicom.DicomElementsWrapper.prototype.getPixelUnit=function(){var e=this.getFromKey("x00281054");return(e=e||this.getFromKey("x00541001"))||"CT"===this.getFromKey("x00080060")&&(e="HU"),e},_.dicom.getFileListFromDicomDir=function(e){var t=new _.dicom.DicomParser,e=(t.parse(e),t.getRawDicomElements());if(void 0===e.x00041220||void 0===e.x00041220.value)_.logger.warn("No Directory Record Sequence found in DICOMDIR.");else{var n=e.x00041220.value;if(0!==n.length){for(var i=[],r=null,o=null,a=0;a<n.length;++a)if(void 0!==n[a].x00041430&&void 0!==n[a].x00041430.value){var s=_.dicom.cleanString(n[a].x00041430.value[0]);if("STUDY"===s)i.push(o=[]);else if("SERIES"===s)o.push(r=[]);else if("IMAGE"===s&&void 0!==n[a].x00041500&&void 0!==n[a].x00041500.value){for(var u=n[a].x00041500.value,l="",c=0;c<u.length;++c)0!==c&&(l+="/"),l+=_.dicom.cleanString(u[c]);r.push(l)}}return i}_.logger.warn("The Directory Record Sequence of the DICOMDIR is empty.")}},_||{}),_=(_.dicom=_.dicom||{},_.getVersion=function(){return"0.31.1"},_.dicom.hasDicomPrefix=function(e){return"DICM"===new Uint8Array(e,128,4).reduce(function(e,t){return e+String.fromCharCode(t)},"")},_.dicom.cleanString=function(e){var t=e;return t=e&&(t=e.trim())[t.length-1]===String.fromCharCode("u200B")?t.substring(0,t.length-1):t},_.dicom.getUtfLabel=function(e){var t="utf-8";return"ISO_IR 100"===e?t="iso-8859-1":"ISO_IR 101"===e?t="iso-8859-2":"ISO_IR 109"===e?t="iso-8859-3":"ISO_IR 110"===e?t="iso-8859-4":"ISO_IR 144"===e?t="iso-8859-5":"ISO_IR 127"===e?t="iso-8859-6":"ISO_IR 126"===e?t="iso-8859-7":"ISO_IR 138"===e?t="iso-8859-8":"ISO_IR 148"===e?t="iso-8859-9":"ISO_IR 13"===e?t="shift-jis":"ISO_IR 166"===e?t="iso-8859-11":"ISO 2022 IR 87"===e?t="iso-2022-jp":"ISO 2022 IR 149"!==e&&"ISO 2022 IR 58"!==e&&("ISO_IR 192"===e?t="utf-8":"GB18030"===e?t="gb18030":"GB2312"===e?t="gb2312":"GBK"===e&&(t="chinese")),t},_.dicom.DefaultTextDecoder=function(){this.decode=function(e){for(var t="",n=0,i=e.length;n<i;++n)t+=String.fromCharCode(e[n]);return t}},_.dicom.getReverseOrientation=function(e){if(!e)return null;for(var t={L:"R",R:"L",A:"P",P:"A",H:"F",F:"H"},n="",i=0;i<e.length;i++){var r=t[e.substring(i,i+1)];r&&(n+=r)}return n},_.dicom.getOrientationName=function(e){var t;return _.utils.arrayEquals(e,[1,0,0,0,1,0])?t="axial":_.utils.arrayEquals(e,[1,0,0,0,0,-1])?t="coronal":_.utils.arrayEquals(e,[0,1,0,0,0,-1])&&(t="sagittal"),t},_.dicom.isImplicitTransferSyntax=function(e){return"1.2.840.10008.1.2"===e},_.dicom.isBigEndianTransferSyntax=function(e){return"1.2.840.10008.1.2.2"===e},_.dicom.isJpegBaselineTransferSyntax=function(e){return"1.2.840.10008.1.2.4.50"===e||"1.2.840.10008.1.2.4.51"===e},_.dicom.isJpegRetiredTransferSyntax=function(e){return null!==e.match(/1.2.840.10008.1.2.4.5/)&&!_.dicom.isJpegBaselineTransferSyntax()&&!_.dicom.isJpegLosslessTransferSyntax()||null!==e.match(/1.2.840.10008.1.2.4.6/)},_.dicom.isJpegLosslessTransferSyntax=function(e){return"1.2.840.10008.1.2.4.57"===e||"1.2.840.10008.1.2.4.70"===e},_.dicom.isJpeglsTransferSyntax=function(e){return null!==e.match(/1.2.840.10008.1.2.4.8/)},_.dicom.isJpeg2000TransferSyntax=function(e){return null!==e.match(/1.2.840.10008.1.2.4.9/)},_.dicom.isRleTransferSyntax=function(e){return null!==e.match(/1.2.840.10008.1.2.5/)},_.dicom.getSyntaxDecompressionName=function(e){var t=null;return _.dicom.isJpeg2000TransferSyntax(e)?t="jpeg2000":_.dicom.isJpegBaselineTransferSyntax(e)?t="jpeg-baseline":_.dicom.isJpegLosslessTransferSyntax(e)?t="jpeg-lossless":_.dicom.isRleTransferSyntax(e)&&(t="rle"),t},_.dicom.isReadSupportedTransferSyntax=function(e){return"1.2.840.10008.1.2"===e||"1.2.840.10008.1.2.1"===e||"1.2.840.10008.1.2.2"===e||_.dicom.isJpegBaselineTransferSyntax(e)||_.dicom.isJpegLosslessTransferSyntax(e)||_.dicom.isJpeg2000TransferSyntax(e)||_.dicom.isRleTransferSyntax(e)},_.dicom.getTransferSyntaxName=function(e){var t="Unknown";return"1.2.840.10008.1.2"===e?t="Little Endian Implicit":"1.2.840.10008.1.2.1"===e?t="Little Endian Explicit":"1.2.840.10008.1.2.1.99"===e?t="Little Endian Deflated Explicit":"1.2.840.10008.1.2.2"===e?t="Big Endian Explicit":_.dicom.isJpegBaselineTransferSyntax(e)?t="1.2.840.10008.1.2.4.50"===e?"JPEG Baseline":"JPEG Extended, Process 2+4":_.dicom.isJpegLosslessTransferSyntax(e)?t="1.2.840.10008.1.2.4.57"===e?"JPEG Lossless, Nonhierarchical (Processes 14)":"JPEG Lossless, Non-hierarchical, 1st Order Prediction":_.dicom.isJpegRetiredTransferSyntax(e)?t="Retired JPEG":_.dicom.isJpeglsTransferSyntax(e)?t="JPEG-LS":_.dicom.isJpeg2000TransferSyntax(e)?t="1.2.840.10008.1.2.4.91"===e?"JPEG 2000 (Lossless or Lossy)":"JPEG 2000 (Lossless only)":"1.2.840.10008.1.2.4.100"===e?t="MPEG2":_.dicom.isRleTransferSyntax(e)&&(t="RLE"),t},_.dicom.guessTransferSyntax=function(e){var t=e.tag.getGroup();if("0x0800"!==t&&"0x0008"!==t)throw new Error("Not a valid DICOM file (no magic DICM word found and first element not in 0x0008 group)");var n=e.vr,i=n.charCodeAt(0),n=n.charCodeAt(1),i=!(65<=i&&i<=90&&65<=n&&n<=90),n=null;if("0x0008"===t)n=i?"1.2.840.10008.1.2":"1.2.840.10008.1.2.1";else{if(i)throw new Error("Not a valid DICOM file (no magic DICM word foundand implicit VR big endian detected)");n="1.2.840.10008.1.2.2"}t={tag:new _.dicom.Tag("0x0002","0x0010"),vr:"UI"};return t.value=[n+" "],t.vl=t.value[0].length,t.startOffset=e.startOffset,t.endOffset=t.startOffset+t.vl,t},_.dicom.getTypedArray=function(t,e,n){var i=null;try{8===t?i=new(0===e?Uint8Array:Int8Array)(n):16===t?i=new(0===e?Uint16Array:Int16Array)(n):32===t&&(i=new(0===e?Uint32Array:Int32Array)(n))}catch(e){e instanceof RangeError&&(t=Math.floor(Math.log(n)/Math.log(2)),_.logger.error("Cannot allocate array of size: "+n+" (>2^"+t+")."))}return i},_.dicom.is32bitVLVR=function(e){return _.dicom.vr32bitVL.includes(e)},_.dicom.getDataElementPrefixByteSize=function(e,t){return!t&&_.dicom.is32bitVLVR(e)?12:8},_.dicom.DicomParser=function(){this.dicomElements={};var t,n=new _.dicom.DefaultTextDecoder,i=n;this.decodeString=function(e){return n.decode(e)},this.decodeSpecialString=function(e){return i.decode(e)},this.getDefaultCharacterSet=function(){return t},this.setDefaultCharacterSet=function(e){t=e,this.setCharacterSet(e)},this.setDecoderCharacterSet=function(e){i=new TextDecoder(e)}},_.dicom.DicomParser.prototype.getRawDicomElements=function(){return this.dicomElements},_.dicom.DicomParser.prototype.getDicomElements=function(){return new _.dicom.DicomElementsWrapper(this.dicomElements)},_.dicom.DicomParser.prototype.readTag=function(e,t){var n=e.readHex(t),e=(t+=Uint16Array.BYTES_PER_ELEMENT,e.readHex(t));return t+=Uint16Array.BYTES_PER_ELEMENT,{tag:new _.dicom.Tag(n,e),endOffset:t}},_.dicom.DicomParser.prototype.readItemDataElement=function(e,t,n){var i={},r=this.readDataElement(e,t,n);if(t=r.endOffset,_.dicom.isSequenceDelimitationItemTag(r.tag))return{data:i,endOffset:r.endOffset,isSeqDelim:!0};if(i[r.tag.getKey()]={tag:r.tag,vr:"NONE",vl:r.vl,undefinedLength:r.undefinedLength},r.undefinedLength)for(var o=!1;!o;)t=(r=this.readDataElement(e,t,n)).endOffset,(o=_.dicom.isItemDelimitationItemTag(r.tag))||(i[r.tag.getKey()]=r);else{var a=t;for(t-=r.vl;t<a;)t=(r=this.readDataElement(e,t,n)).endOffset,i[r.tag.getKey()]=r}return{data:i,endOffset:t,isSeqDelim:!1}},_.dicom.DicomParser.prototype.readPixelItemDataElement=function(e,t,n){for(var i=[],r=this.readDataElement(e,t,n),o=r.vl,a=(t=r.endOffset,!1);!a;)t=(r=this.readDataElement(e,t,n)).endOffset,(a=_.dicom.isSequenceDelimitationItemTag(r.tag))||(r.vr="OB",i.push(r));return{data:i,endOffset:t,offsetTableVl:o}},_.dicom.DicomParser.prototype.readDataElement=function(e,t,n){var i=this.readTag(e,t),r=i.tag,i=(t=i.endOffset,null),o=!1,a=(r.isWithVR()?n?(null===(i=r.getVrFromDictionary())&&(i="UN"),o=!0):(i=this.decodeString(e.readUint8Array(t,2)),t+=2*Uint8Array.BYTES_PER_ELEMENT,(o=_.dicom.is32bitVLVR(i))&&(t+=2*Uint8Array.BYTES_PER_ELEMENT)):(i="NONE",o=!0),0),o=(o?(a=e.readUint32(t),t+=Uint32Array.BYTES_PER_ELEMENT):(a=e.readUint16(t),t+=Uint16Array.BYTES_PER_ELEMENT),!1),s=(4294967295===a&&(o=!0,a=0),r.isPrivate()&&"UN"===i&&0===a&&(i="SQ"),t),u=s+a,l=null;if(_.dicom.isPixelDataTag(r)&&o){var c=this.readPixelItemDataElement(e,t,n);t=c.endOffset,s+=c.offsetTableVl,l=c.data,a=(u=t)-s}else if("SQ"===i){var d,l=[];if(o){for(var g=!1;!g;)g=(d=this.readItemDataElement(e,t,n)).isSeqDelim,t=d.endOffset,g||l.push(d.data);a=(u=t)-s}else if(0!==a){for(var x=t+a;t<x;)d=this.readItemDataElement(e,t,n),l.push(d.data),t=d.endOffset;a=(u=t)-s}}c={tag:r,vr:i,vl:a,startOffset:s,endOffset:u};return o&&(c.undefinedLength=o),l&&(c.items=l),c},_.dicom.DicomParser.prototype.interpretElement=function(e,t,n,i){var r=e.tag,o=e.vl,a=e.vr,s=e.startOffset,u=null,r=_.dicom.isPixelDataTag(r),l=_.dicom.vrTypes[a];if(r)if(e.undefinedLength){for(var u=[],c=0;c<e.items.length;++c)u.push(this.interpretElement(e.items[c],t,n,i));delete e.items}else if(8<i&&"OB"===a&&_.logger.warn("Reading DICOM pixel data with bitsAllocated>8 and OB VR."),u=[],1===i)u.push(t.readBinaryArray(s,o));else if(8===i)0===n?u.push(t.readUint8Array(s,o)):u.push(t.readInt8Array(s,o));else{if(16!==i)throw new Error("Unsupported bits allocated: "+i);0===n?u.push(t.readUint16Array(s,o)):u.push(t.readInt16Array(s,o))}else if(void 0!==l)if("Uint8"===l)u=t.readUint8Array(s,o);else if("Uint16"===l)u=t.readUint16Array(s,o);else if("Uint32"===l)u=t.readUint32Array(s,o);else if("Uint64"===l)u=t.readUint64Array(s,o);else if("Int16"===l)u=t.readInt16Array(s,o);else if("Int32"===l)u=t.readInt32Array(s,o);else if("Int64"===l)u=t.readInt64Array(s,o);else if("Float32"===l)u=t.readFloat32Array(s,o);else if("Float64"===l)u=t.readFloat64Array(s,o);else{if("string"!==l)throw Error("Unknown VR type: "+l);r=t.readUint8Array(s,o);u=(u=_.dicom.charSetString.includes(a)?this.decodeSpecialString(r):this.decodeString(r)).split("\\")}else if("ox"===a)u=8===i?t.readUint8Array(s,o):t.readUint16Array(s,o);else if("xs"===a)u=0===n?t.readUint16Array(s,o):t.readInt16Array(s,o);else if("AT"===a){var d=t.readUint16Array(s,o);u=[];for(var g=0,x=d.length;g<x;g+=2){var S=d[g].toString(16),m=d[g+1].toString(16),h=(h=(h="(")+("0000".substring(0,4-S.length)+S.toUpperCase())+",")+("0000".substring(0,4-m.length)+m.toUpperCase())+")";u.push(h)}}else if("SQ"===a){u=[];for(var f=0;f<e.items.length;++f){for(var p=e.items[f],y={},D=Object.keys(p),v=0;v<D.length;++v){var C=p[D[v]];C.value=this.interpretElement(C,t,n,i),y[D[v]]=C}u.push(y)}delete e.items}else"NONE"===a?u=[]:_.logger.warn("Unknown VR: "+a);return u},_.dicom.DicomParser.prototype.interpret=function(e,t,n,i){for(var r=Object.keys(e),o=0;o<r.length;++o){var a=e[r[o]];void 0===a.value&&(a.value=this.interpretElement(a,t,n,i)),delete a.startOffset,delete a.endOffset}},_.dicom.DicomParser.prototype.parse=function(e){var t=0,n="",i=null,r=new _.dicom.DataReader(e),o=new _.dicom.DataReader(e),t=128,a=this.decodeString(r.readUint8Array(t,4));if(t+=4*Uint8Array.BYTES_PER_ELEMENT,"DICM"===a){(i=this.readDataElement(r,t,!1)).value=this.interpretElement(i,r),t=i.endOffset,this.dicomElements[i.tag.getKey()]=i;for(var s=t+parseInt(i.value[0],10);t<s;)t=(i=this.readDataElement(r,t,!1)).endOffset,this.dicomElements[i.tag.getKey()]=i;if(void 0===(i=this.dicomElements.x00020010))throw new Error("Not a valid DICOM file (no TransferSyntaxUID found)");i.value=this.interpretElement(i,r),n=_.dicom.cleanString(i.value[0])}else{_.logger.warn("No DICM prefix, trying to guess tansfer syntax.");i=this.readDataElement(o,0,!1),a=_.dicom.guessTransferSyntax(i);this.dicomElements[a.tag.getKey()]=a,n=_.dicom.cleanString(a.value[0]),t=0}if(!_.dicom.isReadSupportedTransferSyntax(n))throw new Error("Unsupported DICOM transfer syntax: '"+n+"' ("+_.dicom.getTransferSyntaxName(n)+")");var u,l,c,d=!1;for(_.dicom.isImplicitTransferSyntax(n)&&(d=!0),_.dicom.isBigEndianTransferSyntax(n)&&(o=new _.dicom.DataReader(e,!1));t<e.byteLength;)t=(i=this.readDataElement(o,t,d)).endOffset,void 0===this.dicomElements[i.tag.getKey()]?this.dicomElements[i.tag.getKey()]=i:_.logger.warn("Not saving duplicate tag: "+i.tag.getKey());if(isNaN(t))throw new Error("Problem while parsing, bad offset");if(e.byteLength!==t&&_.logger.warn("Did not reach the end of the buffer: "+t+" != "+e.byteLength),void 0!==this.dicomElements.x7FE00010&&(void(u=0)!==(i=this.dicomElements.x00280103)?(i.value=this.interpretElement(i,o),u=i.value[0]):_.logger.warn("Reading DICOM pixel data with default pixelRepresentation."),l=16,void 0!==(i=this.dicomElements.x00280100)?(i.value=this.interpretElement(i,o),l=i.value[0]):_.logger.warn("Reading DICOM pixel data with default bitsAllocated.")),void 0!==this.getDefaultCharacterSet()&&this.setDecoderCharacterSet(this.getDefaultCharacterSet()),void 0!==(i=this.dicomElements.x00080005)&&(i.value=this.interpretElement(i,o),1===i.value.length?c=_.dicom.cleanString(i.value[0]):(c=_.dicom.cleanString(i.value[1]),_.logger.warn("Unsupported character set with code extensions: '"+c+"'.")),this.setDecoderCharacterSet(_.dicom.getUtfLabel(c))),this.interpret(this.dicomElements,o,u,l),void 0!==(i=this.dicomElements.x7FE00010)&&i.undefinedLength){var g=1,x=(void 0!==this.dicomElements.x00280008&&(g=_.dicom.cleanString(this.dicomElements.x00280008.value[0])),i.value);if(1<x.length&&x.length>g){for(var S=x.length/g,m=[],h=0;h<g;++h){for(var f=h*S,p=0,y=0;y<S;++y)p+=x[f+y].length;for(var D=new x[0].constructor(p),v=0,C=0;C<S;++C)D.set(x[f+C],v),v+=x[f+C].length;m[h]=D}i.value=m}}},_||{}),_=(_.dicom=_.dicom||{},_.dicom.Tag=function(e,t){if(!e||void 0===e)throw new Error("Cannot create tag with no group.");if(6!==e.length||!e.startsWith("0x"))throw new Error("Cannot create tag with badly formed group.");if(!t||void 0===t)throw new Error("Cannot create tag with no element.");if(6!==t.length||!t.startsWith("0x"))throw new Error("Cannot create tag with badly formed element.");this.getGroup=function(){return e},this.getElement=function(){return t}},_.dicom.Tag.prototype.equals=function(e){return null!=e&&this.getGroup()===e.getGroup()&&this.getElement()===e.getElement()},_.dicom.tagCompareFunction=function(e,t){var n=parseInt(e.getGroup())-parseInt(t.getGroup());return n=0===n?parseInt(e.getElement())-parseInt(t.getElement()):n},_.dicom.Tag.prototype.getKey=function(){return"x"+this.getGroup().substring(2)+this.getElement().substring(2)},_.dicom.Tag.prototype.getKey2=function(){return this.getGroup().substring(2)+this.getElement().substring(2)},_.dicom.Tag.prototype.getGroupName=function(){return _.dicom.TagGroups[this.getGroup().substring(1)]},_.dicom.getTagFromKey=function(e){return new _.dicom.Tag("0x"+e.substring(1,5),"0x"+e.substring(5,9))},_.dicom.Tag.prototype.isWithVR=function(){var e=this.getElement();return!("0xFFFE"===this.getGroup()&&("0xE000"===e||"0xE00D"===e||"0xE0DD"===e))},_.dicom.Tag.prototype.isPrivate=function(){return parseInt(this.getGroup().substring(2),16)%2==1},_.dicom.Tag.prototype.getInfoFromDictionary=function(){var e=null;return e=void 0!==_.dicom.dictionary[this.getGroup()]&&void 0!==_.dicom.dictionary[this.getGroup()][this.getElement()]?_.dicom.dictionary[this.getGroup()][this.getElement()]:e},_.dicom.Tag.prototype.getVrFromDictionary=function(){var e=null,t=this.getInfoFromDictionary();return e=null!==t?t[0]:e},_.dicom.Tag.prototype.getNameFromDictionary=function(){var e=null,t=this.getInfoFromDictionary();return e=null!==t?t[2]:e},_.dicom.getTransferSyntaxUIDTag=function(){return new _.dicom.Tag("0x0002","0x0010")},_.dicom.getFileMetaInformationGroupLengthTag=function(){return new _.dicom.Tag("0x0002","0x0000")},_.dicom.isFileMetaInformationGroupLengthTag=function(e){return e.equals(_.dicom.getFileMetaInformationGroupLengthTag())},_.dicom.getItemTag=function(){return new _.dicom.Tag("0xFFFE","0xE000")},_.dicom.isItemTag=function(e){return e.equals(_.dicom.getItemTag())},_.dicom.getItemDelimitationItemTag=function(){return new _.dicom.Tag("0xFFFE","0xE00D")},_.dicom.isItemDelimitationItemTag=function(e){return e.equals(_.dicom.getItemDelimitationItemTag())},_.dicom.getSequenceDelimitationItemTag=function(){return new _.dicom.Tag("0xFFFE","0xE0DD")},_.dicom.isSequenceDelimitationItemTag=function(e){return e.equals(_.dicom.getSequenceDelimitationItemTag())},_.dicom.getPixelDataTag=function(){return new _.dicom.Tag("0x7FE0","0x0010")},_.dicom.isPixelDataTag=function(e){return e.equals(_.dicom.getPixelDataTag())},_.dicom.getTagFromDictionary=function(e){if(null==e)return null;for(var t=null,n=null,i=_.dicom.dictionary,r=Object.keys(i),o=!1,a=0,s=r.length;a<s;++a){for(var u,t=r[a],l=0,c=(u=Object.keys(i[t])).length;l<c;++l)if(n=u[l],i[t][n][2]===e){o=!0;break}if(o)break}var d=null;return d=o?new _.dicom.Tag(t,n):d},_||{}),u=(_.dicom=_.dicom||{},_.dicom.getDwvUIDPrefix=function(){return"1.2.826.0.1.3680043.9.7278.1"},0),_=(_.dicom.getUID=function(e){var t=_.dicom.getDwvUIDPrefix()+".",n="";if("ImplementationClassUID"===e)n=t+_.getVersion();else{var i="."+(new Date).toISOString().replace(/\D/g,"").substring(0,14),r="."+(u+=1),n=t,o=Math.min(e.length,64-(t.length+r.length+i.length));if(1<o){for(var a="",s=0;s<o;++s)a+=e.charCodeAt(s);n+=a.substring(0,o)}n+=i+r}return n},_.dicom.isEven=function(e){return e%2==0},_.dicom.isTypedArrayVr=function(e){e=_.dicom.vrTypes[e];return void 0!==e&&"string"!==e},_.dicom.isStringVr=function(e){e=_.dicom.vrTypes[e];return void 0!==e&&"string"===e},_.dicom.isVrToPad=function(e){return _.dicom.isStringVr(e)||"OB"===e},_.dicom.getVrPad=function(e){var t=0;return t=_.dicom.isStringVr(e)?"UI"===e?"\0":" ":t},_.dicom.uint8ArrayPush=function(e,t){var n=new Uint8Array(e.length+1);return n.set(e),n.set(t,e.length),n},_.dicom.padOBValue=function(e){if(null==e||void 0===e.length)throw new Error("Cannot pad undefined or null OB value.");if(0!==e.length&&void 0!==e[0].length){for(var t=0,n=0;n<e.length;++n)t+=e[n].length;_.dicom.isEven(t)||(e[e.length-1]=_.dicom.uint8ArrayPush(e[e.length-1],0))}else _.dicom.isEven(e.length)||(e=_.dicom.uint8ArrayPush(e,0));return e},_.dicom.flattenArrayOfTypedArrays=function(e){var t=e.length,n=e[0].length;if(void 0===n)return e;for(var i=new e[0].constructor(t*n),r=0;r<t;r++)i.set(e[r],r*n);return i},_.dicom.DefaultTextEncoder=function(){this.encode=function(e){for(var t=new Uint8Array(e.length),n=0,i=e.length;n<i;++n)t[n]=e.charCodeAt(n);return t}},_.dicom.DicomWriter=function(){this.useUnVrForPrivateSq=!1;var i={copy:function(e){return e},remove:function(){return null},clear:function(e){return e.value=[],e},replace:function(e,t){return e.value=[t],e}},t=(this.rules={default:{action:"copy",value:null}},new _.dicom.DefaultTextEncoder),n=t;this.encodeString=function(e){return t.encode(e)},this.encodeSpecialString=function(e){return n.encode(e)},this.useSpecialTextEncoder=function(){n=new TextEncoder},this.anonymisationRules={default:{action:"remove",value:null},PatientName:{action:"replace",value:"Anonymized"},"Meta Element":{action:"copy",value:null},Acquisition:{action:"copy",value:null},"Image Presentation":{action:"copy",value:null},Procedure:{action:"copy",value:null},"Pixel Data":{action:"copy",value:null}},this.getElementToWrite=function(e){var t=e.tag.getGroupName(),n=e.tag.getNameFromDictionary(),n=void 0!==this.rules[e.tag.getKey()]?this.rules[e.tag.getKey()]:null!==n&&void 0!==this.rules[n]?this.rules[n]:void 0!==this.rules[t]?this.rules[t]:this.rules.default;return i[n.action](e,n.value)}},_.dicom.DicomWriter.prototype.writeDataElementItems=function(e,t,n,i){for(var r=0;r<n.length;++r){var o=n[r],a=Object.keys(o);if(0!==a.length){var s=!1,u=(void 0!==o.xFFFEE000.undefinedLength&&(s=o.xFFFEE000.undefinedLength),{tag:_.dicom.getItemTag(),vr:"NONE",vl:s?4294967295:o.xFFFEE000.vl,value:[]});t=this.writeDataElement(e,u,t,i);for(var l=0;l<a.length;++l)"xFFFEE000"!==a[l]&&"xFFFEE00D"!==a[l]&&(t=this.writeDataElement(e,o[a[l]],t,i));s&&(u={tag:_.dicom.getItemDelimitationItemTag(),vr:"NONE",vl:0,value:[]},t=this.writeDataElement(e,u,t,i))}}return t},_.dicom.DicomWriter.prototype.writeDataElementValue=function(e,t,n,i,r){var o=n;if("NONE"!==t.vr)if(i instanceof Uint8Array)n=i.length===8*t.vl?e.writeBinaryArray(n,i):e.writeUint8Array(n,i);else if(i instanceof Int8Array)n=e.writeInt8Array(n,i);else if(i instanceof Uint16Array)n=e.writeUint16Array(n,i);else if(i instanceof Int16Array)n=e.writeInt16Array(n,i);else if(i instanceof Uint32Array)n=e.writeUint32Array(n,i);else if(i instanceof Int32Array)n=e.writeInt32Array(n,i);else if(i instanceof BigUint64Array)n=e.writeUint64Array(n,i);else if(i instanceof BigInt64Array)n=e.writeInt64Array(n,i);else{var a=_.dicom.vrTypes[t.vr];if(void 0!==a)if("Uint8"===a)n=e.writeUint8Array(n,i);else if("Uint16"===a)n=e.writeUint16Array(n,i);else if("Int16"===a)n=e.writeInt16Array(n,i);else if("Uint32"===a)n=e.writeUint32Array(n,i);else if("Int32"===a)n=e.writeInt32Array(n,i);else if("Uint64"===a)n=e.writeUint64Array(n,i);else if("Int64"===a)n=e.writeInt64Array(n,i);else if("Float32"===a)n=e.writeFloat32Array(n,i);else if("Float64"===a)n=e.writeFloat64Array(n,i);else{if("string"!==a)throw Error("Unknown VR type: "+a);n=e.writeUint8Array(n,i)}else if("SQ"===t.vr)n=this.writeDataElementItems(e,n,i,r);else if("AT"===t.vr)for(var s=0;s<i.length;++s){var u=i[s]+"",l=u.substring(1,5),u=u.substring(6,10),l=parseInt(l,16),u=parseInt(u,16),l=new Uint16Array([l,u]);n=e.writeUint16Array(n,l)}else _.logger.warn("Unknown VR: "+t.vr)}return"SQ"!==t.vr&&"NONE"!==t.vr&&(a=n-o)!==t.vl&&_.logger.warn("Offset difference and VL are not equal: "+a+" != "+t.vl+", vr:"+t.vr),n},_.dicom.DicomWriter.prototype.writePixelDataElementValue=function(e,t,n,i,r){var o=!1;if(o=void 0!==t.undefinedLength?t.undefinedLength:o){var a={};a.xFFFEE000={tag:_.dicom.getItemTag(),vr:"NONE",vl:0,value:[]};for(var s=0;s<i.length;++s)a[s]={tag:_.dicom.getItemTag(),vr:t.vr,vl:i[s].length,value:i[s]};n=this.writeDataElementItems(e,n,[a],r)}else{o=i[0];1<i.length&&(o=_.dicom.flattenArrayOfTypedArrays(i)),n=this.writeDataElementValue(e,t,n,o,r)}return n},_.dicom.DicomWriter.prototype.writeDataElement=function(e,t,n,i){var r=t.tag.isWithVR(),o=!(!i&&r)||_.dicom.is32bitVLVR(t.vr),a=(n=e.writeHex(n,t.tag.getGroup()),n=e.writeHex(n,t.tag.getElement()),t.vr),r=(this.useUnVrForPrivateSq&&t.tag.isPrivate()&&"SQ"===a&&(_.logger.warn("Write element using VR=UN for private sequence."),a="UN"),r&&!i&&(n=e.writeUint8Array(n,this.encodeString(a)),o&&(n+=2)),!1),a=("SQ"!==t.vr&&!_.dicom.isPixelDataTag(t.tag)||void 0===t.undefinedLength||(r=t.undefinedLength),!1),s=(_.dicom.isItemTag(t.tag)&&void 0!==t.undefinedLength&&(a=t.undefinedLength),t.vl),a=((r||a)&&(s=4294967295),n=o?e.writeUint32(n,s):e.writeUint16(n,s),t.value);return void 0===a&&(a=[]),n=_.dicom.isPixelDataTag(t.tag)?this.writePixelDataElementValue(e,t,n,a,i):this.writeDataElementValue(e,t,n,a,i),r&&(o={tag:_.dicom.getSequenceDelimitationItemTag(),vr:"NONE",vl:0,value:[]},n=this.writeDataElement(e,o,n,i)),n},_.dicom.DicomWriter.prototype.getBuffer=function(e){for(var t,n,i,r=_.dicom.cleanString(e.x00020010.value[0]),o=_.dicom.isImplicitTransferSyntax(r),r=_.dicom.isBigEndianTransferSyntax(r),a=(void 0===e.x00080005||void 0!==(y=_.dicom.cleanString(e.x00080005.value[0]))&&"ISO-IR 6"!==y&&(_.logger.debug("Change charset to UTF, was: "+y),this.useSpecialTextEncoder(),e.x00080005.value=["ISO_IR 192"]),void 0!==e.x00280100&&(t=e.x00280100.value[0]),132),s=0,u=[],l=[],c=0,d=_.dicom.getFileMetaInformationGroupLengthTag(),g=new _.dicom.Tag("0x0002","0x0001"),x=new _.dicom.Tag("0x0002","0x0012"),S=new _.dicom.Tag("0x0002","0x0013"),m=Object.keys(e),h=0,f=m.length;h<f;++h)null===(n=this.getElementToWrite(e[m[h]]))||d.equals(n.tag)||g.equals(n.tag)||x.equals(n.tag)||S.equals(n.tag)||(s=0,_.dicom.checkUnknownVR(n),this.setElementValue(n,n.value,o,t),s=(s+="Meta Element"===(i=n.tag.getGroupName())?_.dicom.getDataElementPrefixByteSize(n.vr,!1):_.dicom.getDataElementPrefixByteSize(n.vr,o))+n.vl,"Meta Element"===i?(u.push(n),c+=s):l.push(n),a+=s);function p(e,t){return _.dicom.tagCompareFunction(e.tag,t.tag)}var y=_.dicom.getDicomElement("FileMetaInformationVersion"),D=_.dicom.getDataElementPrefixByteSize(y.vr,!1),y=(D+=this.setElementValue(y,[0,1],!1),u.push(y),c+=D,a+=D,_.dicom.getDicomElement("ImplementationClassUID")),D=_.dicom.getDataElementPrefixByteSize(y.vr,!1),y=(D+=this.setElementValue(y,[_.dicom.getUID("ImplementationClassUID")],!1),u.push(y),c+=D,a+=D,_.dicom.getDicomElement("ImplementationVersionName")),D=_.dicom.getDataElementPrefixByteSize(y.vr,!1),v="DWV_"+_.getVersion(),v=(D+=this.setElementValue(y,[v],!1),u.push(y),c+=D,a+=D,u.sort(p),l.sort(p),_.dicom.getDicomElement("FileMetaInformationGroupLength")),y=_.dicom.getDataElementPrefixByteSize(v.vr,!1),D=(a+=y+=this.setElementValue(v,new Uint32Array([c]),!1),new ArrayBuffer(a)),C=new _.dicom.DataWriter(D),T=new _.dicom.DataWriter(D,!r),L=128,L=C.writeUint8Array(L,this.encodeString("DICM"));L=this.writeDataElement(C,v,L,!1);for(var I=0,P=u.length;I<P;++I)L=this.writeDataElement(C,u[I],L,!1);r=132+y+c;L!==r&&_.logger.warn("Bad size calculation... meta offset: "+L+", calculated size:"+r+" (diff:"+(L-r)+")"),T.useUnVrForPrivateSq=this.useUnVrForPrivateSq;for(var w=0,A=l.length;w<A;++w)L=this.writeDataElement(T,l[w],L,o);return L!==a&&_.logger.warn("Bad size calculation... final offset: "+L+", calculated size:"+a+" (diff:"+(L-a)+")"),D},_.dicom.checkUnknownVR=function(e){var t;"UN"===e.vr&&null!==(t=e.tag.getVrFromDictionary())&&e.vr!==t&&(e.vr=t,_.logger.info("Element "+e.tag.getGroup()+" "+e.tag.getElement()+" VR changed from UN to "+e.vr))},_.dicom.getDicomElement=function(e){e=_.dicom.getTagFromDictionary(e);return{tag:e,vr:e.getVrFromDictionary()}},_.dicom.getBpeForVrType=function(e){var t;return"Uint8"===e?t=Uint8Array.BYTES_PER_ELEMENT:"Uint16"===e?t=Uint16Array.BYTES_PER_ELEMENT:"Int16"===e?t=Int16Array.BYTES_PER_ELEMENT:"Uint32"===e?t=Uint32Array.BYTES_PER_ELEMENT:"Int32"===e?t=Int32Array.BYTES_PER_ELEMENT:"Float32"===e?t=Float32Array.BYTES_PER_ELEMENT:"Float64"===e?t=Float64Array.BYTES_PER_ELEMENT:"Uint64"===e?t=BigUint64Array.BYTES_PER_ELEMENT:"Int64"===e&&(t=BigInt64Array.BYTES_PER_ELEMENT),t},_.dicom.DicomWriter.prototype.setElementValue=function(e,t,n,i){var r=0;if("SQ"===e.vr){if(null!==t&&0!==t){var o=[],a=!1;void 0!==e.undefinedLength&&(a=e.undefinedLength,delete e.undefinedLength);for(var s=0;s<t.length;++s){var u=t[s],l={},c=0;if(null!==u&&0!==u){for(var d=Object.keys(u),g=0,x=d.length;g<x;++g){var S=d[g],m=u[S];_.dicom.isItemTag(m.tag)||(c+=this.setElementValue(m,m.value,n,i),l[S]=m,c+=_.dicom.getDataElementPrefixByteSize(m.vr,n))}var h={tag:_.dicom.getItemTag(),vr:"NONE",vl:c,value:[]};a&&(h.undefinedLength=a),l[h.tag.getKey()]=h,c+=_.dicom.getDataElementPrefixByteSize(h.vr,n),a&&(c+=_.dicom.getDataElementPrefixByteSize("NONE",n)),r+=c,o.push(l)}}a&&(r+=_.dicom.getDataElementPrefixByteSize("NONE",n)),e.value=o,e.vl=r,a&&(e.undefinedLength=a)}}else{if(_.dicom.isVrToPad(e.vr)&&(p=_.dicom.getVrPad(e.vr),_.dicom.isStringVr(e.vr)?(p=_.dicom.charSetString.includes(e.vr)?(t=this.encodeSpecialString(t.join("\\")),this.encodeSpecialString(p)):(t=this.encodeString(t.join("\\")),this.encodeString(p)),_.dicom.isEven(t.length)||(t=_.dicom.uint8ArrayPush(t,p))):"OB"===e.vr&&(t=_.dicom.padOBValue(t))),r=0,"AT"===e.vr)r=4*t.length;else if("xs"===e.vr)r=t.length*Uint16Array.BYTES_PER_ELEMENT;else if(_.dicom.isTypedArrayVr(e.vr)||"ox"===e.vr){if(_.dicom.isPixelDataTag(e.tag)&&Array.isArray(t))for(var r=0,f=0;f<t.length;++f)r+=t[f].length;else r=t.length;var p=_.dicom.vrTypes[e.vr];if(_.dicom.isPixelDataTag(e.tag)||"ox"===e.vr)e.undefinedLength?r=(r+=y=_.dicom.getDataElementPrefixByteSize("NONE",n))+y*t.length+y:void 0!==i&&(1===i?r/=8:16===i&&(r*=Uint16Array.BYTES_PER_ELEMENT));else{if(void 0===p)throw Error("Unsupported element: "+e.vr);var y=_.dicom.getBpeForVrType(p);if(void 0===y)throw Error("Unknown bytes per element for VR type: "+p);r*=y}}else r=t.length;e.value=t,e.vl=r}return r},_.dicom.getElementsFromJSONTags=function(e){for(var t=Object.keys(e),n={},i=0,r=t.length;i<r;++i){var o=_.dicom.getTagFromDictionary(t[i]);if(o){var a,s=o.getVrFromDictionary(),u=!1,l=e[t[i]];if("SQ"===s){var c=[];if(void 0!==l.undefinedLength&&(u=l.undefinedLength),void 0!==l.value&&null!==l.value)for(var d=0;d<l.value.length;++d)c.push(_.dicom.getElementsFromJSONTags(l.value[d]));else _.logger.trace("Undefined or null jsonTag SQ value.");a=c}else a=Array.isArray(l)?l:[l];s={tag:o,vr:s,value:a};u&&(s.undefinedLength=u),n[o.getKey()]=s}}return n},_||{}),_=(_.dicom=_.dicom||{},_.dicom.dictionary={"0x0000":{"0x0000":["UL","1","CommandGroupLength"],"0x0001":["UL","1","CommandLengthToEnd"],"0x0002":["UI","1","AffectedSOPClassUID"],"0x0003":["UI","1","RequestedSOPClassUID"],"0x0010":["SH","1","CommandRecognitionCode"],"0x0100":["US","1","CommandField"],"0x0110":["US","1","MessageID"],"0x0120":["US","1","MessageIDBeingRespondedTo"],"0x0200":["AE","1","Initiator"],"0x0300":["AE","1","Receiver"],"0x0400":["AE","1","FindLocation"],"0x0600":["AE","1","MoveDestination"],"0x0700":["US","1","Priority"],"0x0800":["US","1","CommandDataSetType"],"0x0850":["US","1","NumberOfMatches"],"0x0860":["US","1","ResponseSequenceNumber"],"0x0900":["US","1","Status"],"0x0901":["AT","1-n","OffendingElement"],"0x0902":["LO","1","ErrorComment"],"0x0903":["US","1","ErrorID"],"0x1000":["UI","1","AffectedSOPInstanceUID"],"0x1001":["UI","1","RequestedSOPInstanceUID"],"0x1002":["US","1","EventTypeID"],"0x1005":["AT","1-n","AttributeIdentifierList"],"0x1008":["US","1","ActionTypeID"],"0x1020":["US","1","NumberOfRemainingSuboperations"],"0x1021":["US","1","NumberOfCompletedSuboperations"],"0x1022":["US","1","NumberOfFailedSuboperations"],"0x1023":["US","1","NumberOfWarningSuboperations"],"0x1030":["AE","1","MoveOriginatorApplicationEntityTitle"],"0x1031":["US","1","MoveOriginatorMessageID"],"0x4000":["LT","1","DialogReceiver"],"0x4010":["LT","1","TerminalType"],"0x5010":["SH","1","MessageSetID"],"0x5020":["SH","1","EndMessageID"],"0x5110":["LT","1","DisplayFormat"],"0x5120":["LT","1","PagePositionID"],"0x5130":["CS","1","TextFormatID"],"0x5140":["CS","1","NormalReverse"],"0x5150":["CS","1","AddGrayScale"],"0x5160":["CS","1","Borders"],"0x5170":["IS","1","Copies"],"0x5180":["CS","1","CommandMagnificationType"],"0x5190":["CS","1","Erase"],"0x51A0":["CS","1","Print"],"0x51B0":["US","1-n","Overlays"]},"0x0002":{"0x0000":["UL","1","FileMetaInformationGroupLength"],"0x0001":["OB","1","FileMetaInformationVersion"],"0x0002":["UI","1","MediaStorageSOPClassUID"],"0x0003":["UI","1","MediaStorageSOPInstanceUID"],"0x0010":["UI","1","TransferSyntaxUID"],"0x0012":["UI","1","ImplementationClassUID"],"0x0013":["SH","1","ImplementationVersionName"],"0x0016":["AE","1","SourceApplicationEntityTitle"],"0x0017":["AE","1","SendingApplicationEntityTitle"],"0x0018":["AE","1","ReceivingApplicationEntityTitle"],"0x0026":["UR","1","SourcePresentationAddress"],"0x0027":["UR","1","SendingPresentationAddress"],"0x0028":["UR","1","ReceivingPresentationAddress"],"0x0031":["OB","1","RTVMetaInformationVersion"],"0x0032":["UI","1","RTVCommunicationSOPClassUID"],"0x0033":["UI","1","RTVCommunicationSOPInstanceUID"],"0x0035":["OB","1","RTVSourceIdentifier"],"0x0036":["OB","1","RTVFlowIdentifier"],"0x0037":["UL","1","RTVFlowRTPSamplingRate"],"0x0038":["FD","1","RTVFlowActualFrameDuration"],"0x0100":["UI","1","PrivateInformationCreatorUID"],"0x0102":["OB","1","PrivateInformation"]},"0x0004":{"0x0000":["UL","1","GenericGroupLength"],"0x1130":["CS","1","FileSetID"],"0x1141":["CS","1-8","FileSetDescriptorFileID"],"0x1142":["CS","1","SpecificCharacterSetOfFileSetDescriptorFile"],"0x1200":["UL","1","OffsetOfTheFirstDirectoryRecordOfTheRootDirectoryEntity"],"0x1202":["UL","1","OffsetOfTheLastDirectoryRecordOfTheRootDirectoryEntity"],"0x1212":["US","1","FileSetConsistencyFlag"],"0x1220":["SQ","1","DirectoryRecordSequence"],"0x1400":["UL","1","OffsetOfTheNextDirectoryRecord"],"0x1410":["US","1","RecordInUseFlag"],"0x1420":["UL","1","OffsetOfReferencedLowerLevelDirectoryEntity"],"0x1430":["CS","1","DirectoryRecordType"],"0x1432":["UI","1","PrivateRecordUID"],"0x1500":["CS","1-8","ReferencedFileID"],"0x1504":["UL","1","MRDRDirectoryRecordOffset"],"0x1510":["UI","1","ReferencedSOPClassUIDInFile"],"0x1511":["UI","1","ReferencedSOPInstanceUIDInFile"],"0x1512":["UI","1","ReferencedTransferSyntaxUIDInFile"],"0x151A":["UI","1-n","ReferencedRelatedGeneralSOPClassUIDInFile"],"0x1600":["UL","1","NumberOfReferences"]},"0x0008":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["UL","1","LengthToEnd"],"0x0005":["CS","1-n","SpecificCharacterSet"],"0x0006":["SQ","1","LanguageCodeSequence"],"0x0008":["CS","2-n","ImageType"],"0x0010":["SH","1","RecognitionCode"],"0x0012":["DA","1","InstanceCreationDate"],"0x0013":["TM","1","InstanceCreationTime"],"0x0014":["UI","1","InstanceCreatorUID"],"0x0015":["DT","1","InstanceCoercionDateTime"],"0x0016":["UI","1","SOPClassUID"],"0x0018":["UI","1","SOPInstanceUID"],"0x001A":["UI","1-n","RelatedGeneralSOPClassUID"],"0x001B":["UI","1","OriginalSpecializedSOPClassUID"],"0x0020":["DA","1","StudyDate"],"0x0021":["DA","1","SeriesDate"],"0x0022":["DA","1","AcquisitionDate"],"0x0023":["DA","1","ContentDate"],"0x0024":["DA","1","OverlayDate"],"0x0025":["DA","1","CurveDate"],"0x002A":["DT","1","AcquisitionDateTime"],"0x0030":["TM","1","StudyTime"],"0x0031":["TM","1","SeriesTime"],"0x0032":["TM","1","AcquisitionTime"],"0x0033":["TM","1","ContentTime"],"0x0034":["TM","1","OverlayTime"],"0x0035":["TM","1","CurveTime"],"0x0040":["US","1","DataSetType"],"0x0041":["LO","1","DataSetSubtype"],"0x0042":["CS","1","NuclearMedicineSeriesType"],"0x0050":["SH","1","AccessionNumber"],"0x0051":["SQ","1","IssuerOfAccessionNumberSequence"],"0x0052":["CS","1","QueryRetrieveLevel"],"0x0053":["CS","1","QueryRetrieveView"],"0x0054":["AE","1-n","RetrieveAETitle"],"0x0055":["AE","1","StationAETitle"],"0x0056":["CS","1","InstanceAvailability"],"0x0058":["UI","1-n","FailedSOPInstanceUIDList"],"0x0060":["CS","1","Modality"],"0x0061":["CS","1-n","ModalitiesInStudy"],"0x0062":["UI","1-n","SOPClassesInStudy"],"0x0063":["SQ","1","AnatomicRegionsInStudyCodeSequence"],"0x0064":["CS","1","ConversionType"],"0x0068":["CS","1","PresentationIntentType"],"0x0070":["LO","1","Manufacturer"],"0x0080":["LO","1","InstitutionName"],"0x0081":["ST","1","InstitutionAddress"],"0x0082":["SQ","1","InstitutionCodeSequence"],"0x0090":["PN","1","ReferringPhysicianName"],"0x0092":["ST","1","ReferringPhysicianAddress"],"0x0094":["SH","1-n","ReferringPhysicianTelephoneNumbers"],"0x0096":["SQ","1","ReferringPhysicianIdentificationSequence"],"0x009C":["PN","1-n","ConsultingPhysicianName"],"0x009D":["SQ","1","ConsultingPhysicianIdentificationSequence"],"0x0100":["SH","1","CodeValue"],"0x0101":["LO","1","ExtendedCodeValue"],"0x0102":["SH","1","CodingSchemeDesignator"],"0x0103":["SH","1","CodingSchemeVersion"],"0x0104":["LO","1","CodeMeaning"],"0x0105":["CS","1","MappingResource"],"0x0106":["DT","1","ContextGroupVersion"],"0x0107":["DT","1","ContextGroupLocalVersion"],"0x0108":["LT","1","ExtendedCodeMeaning"],"0x0109":["SQ","1","CodingSchemeResourcesSequence"],"0x010A":["CS","1","CodingSchemeURLType"],"0x010B":["CS","1","ContextGroupExtensionFlag"],"0x010C":["UI","1","CodingSchemeUID"],"0x010D":["UI","1","ContextGroupExtensionCreatorUID"],"0x010E":["UR","1","CodingSchemeURL"],"0x010F":["CS","1","ContextIdentifier"],"0x0110":["SQ","1","CodingSchemeIdentificationSequence"],"0x0112":["LO","1","CodingSchemeRegistry"],"0x0114":["ST","1","CodingSchemeExternalID"],"0x0115":["ST","1","CodingSchemeName"],"0x0116":["ST","1","CodingSchemeResponsibleOrganization"],"0x0117":["UI","1","ContextUID"],"0x0118":["UI","1","MappingResourceUID"],"0x0119":["UC","1","LongCodeValue"],"0x0120":["UR","1","URNCodeValue"],"0x0121":["SQ","1","EquivalentCodeSequence"],"0x0122":["LO","1","MappingResourceName"],"0x0123":["SQ","1","ContextGroupIdentificationSequence"],"0x0124":["SQ","1","MappingResourceIdentificationSequence"],"0x0201":["SH","1","TimezoneOffsetFromUTC"],"0x0202":["","",""],"0x0220":["SQ","1","ResponsibleGroupCodeSequence"],"0x0221":["CS","1","EquipmentModality"],"0x0222":["LO","1","ManufacturerRelatedModelGroup"],"0x0300":["SQ","1","PrivateDataElementCharacteristicsSequence"],"0x0301":["US","1","PrivateGroupReference"],"0x0302":["LO","1","PrivateCreatorReference"],"0x0303":["CS","1","BlockIdentifyingInformationStatus"],"0x0304":["US","1-n","NonidentifyingPrivateElements"],"0x0305":["SQ","1","DeidentificationActionSequence"],"0x0306":["US","1-n","IdentifyingPrivateElements"],"0x0307":["CS","1","DeidentificationAction"],"0x0308":["US","1","PrivateDataElement"],"0x0309":["UL","1-3","PrivateDataElementValueMultiplicity"],"0x030A":["CS","1","PrivateDataElementValueRepresentation"],"0x030B":["UL","1-2","PrivateDataElementNumberOfItems"],"0x030C":["UC","1","PrivateDataElementName"],"0x030D":["UC","1","PrivateDataElementKeyword"],"0x030E":["UT","1","PrivateDataElementDescription"],"0x030F":["UT","1","PrivateDataElementEncoding"],"0x0310":["SQ","1","PrivateDataElementDefinitionSequence"],"0x1000":["AE","1","NetworkID"],"0x1010":["SH","1","StationName"],"0x1030":["LO","1","StudyDescription"],"0x1032":["SQ","1","ProcedureCodeSequence"],"0x103E":["LO","1","SeriesDescription"],"0x103F":["SQ","1","SeriesDescriptionCodeSequence"],"0x1040":["LO","1","InstitutionalDepartmentName"],"0x1041":["SQ","1","InstitutionalDepartmentTypeCodeSequence"],"0x1048":["PN","1-n","PhysiciansOfRecord"],"0x1049":["SQ","1","PhysiciansOfRecordIdentificationSequence"],"0x1050":["PN","1-n","PerformingPhysicianName"],"0x1052":["SQ","1","PerformingPhysicianIdentificationSequence"],"0x1060":["PN","1-n","NameOfPhysiciansReadingStudy"],"0x1062":["SQ","1","PhysiciansReadingStudyIdentificationSequence"],"0x1070":["PN","1-n","OperatorsName"],"0x1072":["SQ","1","OperatorIdentificationSequence"],"0x1080":["LO","1-n","AdmittingDiagnosesDescription"],"0x1084":["SQ","1","AdmittingDiagnosesCodeSequence"],"0x1090":["LO","1","ManufacturerModelName"],"0x1100":["SQ","1","ReferencedResultsSequence"],"0x1110":["SQ","1","ReferencedStudySequence"],"0x1111":["SQ","1","ReferencedPerformedProcedureStepSequence"],"0x1115":["SQ","1","ReferencedSeriesSequence"],"0x1120":["SQ","1","ReferencedPatientSequence"],"0x1125":["SQ","1","ReferencedVisitSequence"],"0x1130":["SQ","1","ReferencedOverlaySequence"],"0x1134":["SQ","1","ReferencedStereometricInstanceSequence"],"0x113A":["SQ","1","ReferencedWaveformSequence"],"0x1140":["SQ","1","ReferencedImageSequence"],"0x1145":["SQ","1","ReferencedCurveSequence"],"0x114A":["SQ","1","ReferencedInstanceSequence"],"0x114B":["SQ","1","ReferencedRealWorldValueMappingInstanceSequence"],"0x1150":["UI","1","ReferencedSOPClassUID"],"0x1155":["UI","1","ReferencedSOPInstanceUID"],"0x1156":["SQ","1","DefinitionSourceSequence"],"0x115A":["UI","1-n","SOPClassesSupported"],"0x1160":["IS","1-n","ReferencedFrameNumber"],"0x1161":["UL","1-n","SimpleFrameList"],"0x1162":["UL","3-3n","CalculatedFrameList"],"0x1163":["FD","2","TimeRange"],"0x1164":["SQ","1","FrameExtractionSequence"],"0x1167":["UI","1","MultiFrameSourceSOPInstanceUID"],"0x1190":["UR","1","RetrieveURL"],"0x1195":["UI","1","TransactionUID"],"0x1196":["US","1","WarningReason"],"0x1197":["US","1","FailureReason"],"0x1198":["SQ","1","FailedSOPSequence"],"0x1199":["SQ","1","ReferencedSOPSequence"],"0x119A":["SQ","1","OtherFailuresSequence"],"0x1200":["SQ","1","StudiesContainingOtherReferencedInstancesSequence"],"0x1250":["SQ","1","RelatedSeriesSequence"],"0x2110":["CS","1","LossyImageCompressionRetired"],"0x2111":["ST","1","DerivationDescription"],"0x2112":["SQ","1","SourceImageSequence"],"0x2120":["SH","1","StageName"],"0x2122":["IS","1","StageNumber"],"0x2124":["IS","1","NumberOfStages"],"0x2127":["SH","1","ViewName"],"0x2128":["IS","1","ViewNumber"],"0x2129":["IS","1","NumberOfEventTimers"],"0x212A":["IS","1","NumberOfViewsInStage"],"0x2130":["DS","1-n","EventElapsedTimes"],"0x2132":["LO","1-n","EventTimerNames"],"0x2133":["SQ","1","EventTimerSequence"],"0x2134":["FD","1","EventTimeOffset"],"0x2135":["SQ","1","EventCodeSequence"],"0x2142":["IS","1","StartTrim"],"0x2143":["IS","1","StopTrim"],"0x2144":["IS","1","RecommendedDisplayFrameRate"],"0x2200":["CS","1","TransducerPosition"],"0x2204":["CS","1","TransducerOrientation"],"0x2208":["CS","1","AnatomicStructure"],"0x2218":["SQ","1","AnatomicRegionSequence"],"0x2220":["SQ","1","AnatomicRegionModifierSequence"],"0x2228":["SQ","1","PrimaryAnatomicStructureSequence"],"0x2229":["SQ","1","AnatomicStructureSpaceOrRegionSequence"],"0x2230":["SQ","1","PrimaryAnatomicStructureModifierSequence"],"0x2240":["SQ","1","TransducerPositionSequence"],"0x2242":["SQ","1","TransducerPositionModifierSequence"],"0x2244":["SQ","1","TransducerOrientationSequence"],"0x2246":["SQ","1","TransducerOrientationModifierSequence"],"0x2251":["SQ","1","AnatomicStructureSpaceOrRegionCodeSequenceTrial"],"0x2253":["SQ","1","AnatomicPortalOfEntranceCodeSequenceTrial"],"0x2255":["SQ","1","AnatomicApproachDirectionCodeSequenceTrial"],"0x2256":["ST","1","AnatomicPerspectiveDescriptionTrial"],"0x2257":["SQ","1","AnatomicPerspectiveCodeSequenceTrial"],"0x2258":["ST","1","AnatomicLocationOfExaminingInstrumentDescriptionTrial"],"0x2259":["SQ","1","AnatomicLocationOfExaminingInstrumentCodeSequenceTrial"],"0x225A":["SQ","1","AnatomicStructureSpaceOrRegionModifierCodeSequenceTrial"],"0x225C":["SQ","1","OnAxisBackgroundAnatomicStructureCodeSequenceTrial"],"0x3001":["SQ","1","AlternateRepresentationSequence"],"0x3002":["UI","1-n","AvailableTransferSyntaxUID"],"0x3010":["UI","1-n","IrradiationEventUID"],"0x3011":["SQ","1","SourceIrradiationEventSequence"],"0x3012":["UI","1","RadiopharmaceuticalAdministrationEventUID"],"0x4000":["LT","1","IdentifyingComments"],"0x9007":["CS","4","FrameType"],"0x9092":["SQ","1","ReferencedImageEvidenceSequence"],"0x9121":["SQ","1","ReferencedRawDataSequence"],"0x9123":["UI","1","CreatorVersionUID"],"0x9124":["SQ","1","DerivationImageSequence"],"0x9154":["SQ","1","SourceImageEvidenceSequence"],"0x9205":["CS","1","PixelPresentation"],"0x9206":["CS","1","VolumetricProperties"],"0x9207":["CS","1","VolumeBasedCalculationTechnique"],"0x9208":["CS","1","ComplexImageComponent"],"0x9209":["CS","1","AcquisitionContrast"],"0x9215":["SQ","1","DerivationCodeSequence"],"0x9237":["SQ","1","ReferencedPresentationStateSequence"],"0x9410":["SQ","1","ReferencedOtherPlaneSequence"],"0x9458":["SQ","1","FrameDisplaySequence"],"0x9459":["FL","1","RecommendedDisplayFrameRateInFloat"],"0x9460":["CS","1","SkipFrameRangeFlag"]},"0x0010":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["PN","1","PatientName"],"0x0020":["LO","1","PatientID"],"0x0021":["LO","1","IssuerOfPatientID"],"0x0022":["CS","1","TypeOfPatientID"],"0x0024":["SQ","1","IssuerOfPatientIDQualifiersSequence"],"0x0026":["SQ","1","SourcePatientGroupIdentificationSequence"],"0x0027":["SQ","1","GroupOfPatientsIdentificationSequence"],"0x0028":["US","3","SubjectRelativePositionInImage"],"0x0030":["DA","1","PatientBirthDate"],"0x0032":["TM","1","PatientBirthTime"],"0x0033":["LO","1","PatientBirthDateInAlternativeCalendar"],"0x0034":["LO","1","PatientDeathDateInAlternativeCalendar"],"0x0035":["CS","1","PatientAlternativeCalendar"],"0x0040":["CS","1","PatientSex"],"0x0050":["SQ","1","PatientInsurancePlanCodeSequence"],"0x0101":["SQ","1","PatientPrimaryLanguageCodeSequence"],"0x0102":["SQ","1","PatientPrimaryLanguageModifierCodeSequence"],"0x0200":["CS","1","QualityControlSubject"],"0x0201":["SQ","1","QualityControlSubjectTypeCodeSequence"],"0x0212":["UC","1","StrainDescription"],"0x0213":["LO","1","StrainNomenclature"],"0x0214":["LO","1","StrainStockNumber"],"0x0215":["SQ","1","StrainSourceRegistryCodeSequence"],"0x0216":["SQ","1","StrainStockSequence"],"0x0217":["LO","1","StrainSource"],"0x0218":["UT","1","StrainAdditionalInformation"],"0x0219":["SQ","1","StrainCodeSequence"],"0x0221":["SQ","1","GeneticModificationsSequence"],"0x0222":["UC","1","GeneticModificationsDescription"],"0x0223":["LO","1","GeneticModificationsNomenclature"],"0x0229":["SQ","1","GeneticModificationsCodeSequence"],"0x1000":["LO","1-n","OtherPatientIDs"],"0x1001":["PN","1-n","OtherPatientNames"],"0x1002":["SQ","1","OtherPatientIDsSequence"],"0x1005":["PN","1","PatientBirthName"],"0x1010":["AS","1","PatientAge"],"0x1020":["DS","1","PatientSize"],"0x1021":["SQ","1","PatientSizeCodeSequence"],"0x1022":["DS","1","PatientBodyMassIndex"],"0x1023":["DS","1","MeasuredAPDimension"],"0x1024":["DS","1","MeasuredLateralDimension"],"0x1030":["DS","1","PatientWeight"],"0x1040":["LO","1","PatientAddress"],"0x1050":["LO","1-n","InsurancePlanIdentification"],"0x1060":["PN","1","PatientMotherBirthName"],"0x1080":["LO","1","MilitaryRank"],"0x1081":["LO","1","BranchOfService"],"0x1090":["LO","1","MedicalRecordLocator"],"0x1100":["SQ","1","ReferencedPatientPhotoSequence"],"0x2000":["LO","1-n","MedicalAlerts"],"0x2110":["LO","1-n","Allergies"],"0x2150":["LO","1","CountryOfResidence"],"0x2152":["LO","1","RegionOfResidence"],"0x2154":["SH","1-n","PatientTelephoneNumbers"],"0x2155":["LT","1","PatientTelecomInformation"],"0x2160":["SH","1","EthnicGroup"],"0x2180":["SH","1","Occupation"],"0x21A0":["CS","1","SmokingStatus"],"0x21B0":["LT","1","AdditionalPatientHistory"],"0x21C0":["US","1","PregnancyStatus"],"0x21D0":["DA","1","LastMenstrualDate"],"0x21F0":["LO","1","PatientReligiousPreference"],"0x2201":["LO","1","PatientSpeciesDescription"],"0x2202":["SQ","1","PatientSpeciesCodeSequence"],"0x2203":["CS","1","PatientSexNeutered"],"0x2210":["CS","1","AnatomicalOrientationType"],"0x2292":["LO","1","PatientBreedDescription"],"0x2293":["SQ","1","PatientBreedCodeSequence"],"0x2294":["SQ","1","BreedRegistrationSequence"],"0x2295":["LO","1","BreedRegistrationNumber"],"0x2296":["SQ","1","BreedRegistryCodeSequence"],"0x2297":["PN","1","ResponsiblePerson"],"0x2298":["CS","1","ResponsiblePersonRole"],"0x2299":["LO","1","ResponsibleOrganization"],"0x4000":["LT","1","PatientComments"],"0x9431":["FL","1","ExaminedBodyThickness"]},"0x0012":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["LO","1","ClinicalTrialSponsorName"],"0x0020":["LO","1","ClinicalTrialProtocolID"],"0x0021":["LO","1","ClinicalTrialProtocolName"],"0x0030":["LO","1","ClinicalTrialSiteID"],"0x0031":["LO","1","ClinicalTrialSiteName"],"0x0040":["LO","1","ClinicalTrialSubjectID"],"0x0042":["LO","1","ClinicalTrialSubjectReadingID"],"0x0050":["LO","1","ClinicalTrialTimePointID"],"0x0051":["ST","1","ClinicalTrialTimePointDescription"],"0x0052":["FD","1","LongitudinalTemporalOffsetFromEvent"],"0x0053":["CS","1","LongitudinalTemporalEventType"],"0x0060":["LO","1","ClinicalTrialCoordinatingCenterName"],"0x0062":["CS","1","PatientIdentityRemoved"],"0x0063":["LO","1-n","DeidentificationMethod"],"0x0064":["SQ","1","DeidentificationMethodCodeSequence"],"0x0071":["LO","1","ClinicalTrialSeriesID"],"0x0072":["LO","1","ClinicalTrialSeriesDescription"],"0x0081":["LO","1","ClinicalTrialProtocolEthicsCommitteeName"],"0x0082":["LO","1","ClinicalTrialProtocolEthicsCommitteeApprovalNumber"],"0x0083":["SQ","1","ConsentForClinicalTrialUseSequence"],"0x0084":["CS","1","DistributionType"],"0x0085":["CS","1","ConsentForDistributionFlag"],"0x0086":["DA","1","EthicsCommitteeApprovalEffectivenessStartDate"],"0x0087":["DA","1","EthicsCommitteeApprovalEffectivenessEndDate"]},"0x0014":{"0x0000":["UL","1","GenericGroupLength"],"0x0023":["ST","1","CADFileFormat"],"0x0024":["ST","1","ComponentReferenceSystem"],"0x0025":["ST","1","ComponentManufacturingProcedure"],"0x0028":["ST","1","ComponentManufacturer"],"0x0030":["DS","1-n","MaterialThickness"],"0x0032":["DS","1-n","MaterialPipeDiameter"],"0x0034":["DS","1-n","MaterialIsolationDiameter"],"0x0042":["ST","1","MaterialGrade"],"0x0044":["ST","1","MaterialPropertiesDescription"],"0x0045":["ST","1","MaterialPropertiesFileFormatRetired"],"0x0046":["LT","1","MaterialNotes"],"0x0050":["CS","1","ComponentShape"],"0x0052":["CS","1","CurvatureType"],"0x0054":["DS","1","OuterDiameter"],"0x0056":["DS","1","InnerDiameter"],"0x0100":["LO","1-n","ComponentWelderIDs"],"0x0101":["CS","1","SecondaryApprovalStatus"],"0x0102":["DA","1","SecondaryReviewDate"],"0x0103":["TM","1","SecondaryReviewTime"],"0x0104":["PN","1","SecondaryReviewerName"],"0x0105":["ST","1","RepairID"],"0x0106":["SQ","1","MultipleComponentApprovalSequence"],"0x0107":["CS","1-n","OtherApprovalStatus"],"0x0108":["CS","1-n","OtherSecondaryApprovalStatus"],"0x1010":["ST","1","ActualEnvironmentalConditions"],"0x1020":["DA","1","ExpiryDate"],"0x1040":["ST","1","EnvironmentalConditions"],"0x2002":["SQ","1","EvaluatorSequence"],"0x2004":["IS","1","EvaluatorNumber"],"0x2006":["PN","1","EvaluatorName"],"0x2008":["IS","1","EvaluationAttempt"],"0x2012":["SQ","1","IndicationSequence"],"0x2014":["IS","1","IndicationNumber"],"0x2016":["SH","1","IndicationLabel"],"0x2018":["ST","1","IndicationDescription"],"0x201A":["CS","1-n","IndicationType"],"0x201C":["CS","1","IndicationDisposition"],"0x201E":["SQ","1","IndicationROISequence"],"0x2030":["SQ","1","IndicationPhysicalPropertySequence"],"0x2032":["SH","1","PropertyLabel"],"0x2202":["IS","1","CoordinateSystemNumberOfAxes"],"0x2204":["SQ","1","CoordinateSystemAxesSequence"],"0x2206":["ST","1","CoordinateSystemAxisDescription"],"0x2208":["CS","1","CoordinateSystemDataSetMapping"],"0x220A":["IS","1","CoordinateSystemAxisNumber"],"0x220C":["CS","1","CoordinateSystemAxisType"],"0x220E":["CS","1","CoordinateSystemAxisUnits"],"0x2210":["OB","1","CoordinateSystemAxisValues"],"0x2220":["SQ","1","CoordinateSystemTransformSequence"],"0x2222":["ST","1","TransformDescription"],"0x2224":["IS","1","TransformNumberOfAxes"],"0x2226":["IS","1-n","TransformOrderOfAxes"],"0x2228":["CS","1","TransformedAxisUnits"],"0x222A":["DS","1-n","CoordinateSystemTransformRotationAndScaleMatrix"],"0x222C":["DS","1-n","CoordinateSystemTransformTranslationMatrix"],"0x3011":["DS","1","InternalDetectorFrameTime"],"0x3012":["DS","1","NumberOfFramesIntegrated"],"0x3020":["SQ","1","DetectorTemperatureSequence"],"0x3022":["ST","1","SensorName"],"0x3024":["DS","1","HorizontalOffsetOfSensor"],"0x3026":["DS","1","VerticalOffsetOfSensor"],"0x3028":["DS","1","SensorTemperature"],"0x3040":["SQ","1","DarkCurrentSequence"],"0x3050":["ox","1","DarkCurrentCounts"],"0x3060":["SQ","1","GainCorrectionReferenceSequence"],"0x3070":["ox","1","AirCounts"],"0x3071":["DS","1","KVUsedInGainCalibration"],"0x3072":["DS","1","MAUsedInGainCalibration"],"0x3073":["DS","1","NumberOfFramesUsedForIntegration"],"0x3074":["LO","1","FilterMaterialUsedInGainCalibration"],"0x3075":["DS","1","FilterThicknessUsedInGainCalibration"],"0x3076":["DA","1","DateOfGainCalibration"],"0x3077":["TM","1","TimeOfGainCalibration"],"0x3080":["OB","1","BadPixelImage"],"0x3099":["LT","1","CalibrationNotes"],"0x3100":["LT","1","LinearityCorrectionTechnique"],"0x3101":["LT","1","BeamHardeningCorrectionTechnique"],"0x4002":["SQ","1","PulserEquipmentSequence"],"0x4004":["CS","1","PulserType"],"0x4006":["LT","1","PulserNotes"],"0x4008":["SQ","1","ReceiverEquipmentSequence"],"0x400A":["CS","1","AmplifierType"],"0x400C":["LT","1","ReceiverNotes"],"0x400E":["SQ","1","PreAmplifierEquipmentSequence"],"0x400F":["LT","1","PreAmplifierNotes"],"0x4010":["SQ","1","TransmitTransducerSequence"],"0x4011":["SQ","1","ReceiveTransducerSequence"],"0x4012":["US","1","NumberOfElements"],"0x4013":["CS","1","ElementShape"],"0x4014":["DS","1","ElementDimensionA"],"0x4015":["DS","1","ElementDimensionB"],"0x4016":["DS","1","ElementPitchA"],"0x4017":["DS","1","MeasuredBeamDimensionA"],"0x4018":["DS","1","MeasuredBeamDimensionB"],"0x4019":["DS","1","LocationOfMeasuredBeamDiameter"],"0x401A":["DS","1","NominalFrequency"],"0x401B":["DS","1","MeasuredCenterFrequency"],"0x401C":["DS","1","MeasuredBandwidth"],"0x401D":["DS","1","ElementPitchB"],"0x4020":["SQ","1","PulserSettingsSequence"],"0x4022":["DS","1","PulseWidth"],"0x4024":["DS","1","ExcitationFrequency"],"0x4026":["CS","1","ModulationType"],"0x4028":["DS","1","Damping"],"0x4030":["SQ","1","ReceiverSettingsSequence"],"0x4031":["DS","1","AcquiredSoundpathLength"],"0x4032":["CS","1","AcquisitionCompressionType"],"0x4033":["IS","1","AcquisitionSampleSize"],"0x4034":["DS","1","RectifierSmoothing"],"0x4035":["SQ","1","DACSequence"],"0x4036":["CS","1","DACType"],"0x4038":["DS","1-n","DACGainPoints"],"0x403A":["DS","1-n","DACTimePoints"],"0x403C":["DS","1-n","DACAmplitude"],"0x4040":["SQ","1","PreAmplifierSettingsSequence"],"0x4050":["SQ","1","TransmitTransducerSettingsSequence"],"0x4051":["SQ","1","ReceiveTransducerSettingsSequence"],"0x4052":["DS","1","IncidentAngle"],"0x4054":["ST","1","CouplingTechnique"],"0x4056":["ST","1","CouplingMedium"],"0x4057":["DS","1","CouplingVelocity"],"0x4058":["DS","1","ProbeCenterLocationX"],"0x4059":["DS","1","ProbeCenterLocationZ"],"0x405A":["DS","1","SoundPathLength"],"0x405C":["ST","1","DelayLawIdentifier"],"0x4060":["SQ","1","GateSettingsSequence"],"0x4062":["DS","1","GateThreshold"],"0x4064":["DS","1","VelocityOfSound"],"0x4070":["SQ","1","CalibrationSettingsSequence"],"0x4072":["ST","1","CalibrationProcedure"],"0x4074":["SH","1","ProcedureVersion"],"0x4076":["DA","1","ProcedureCreationDate"],"0x4078":["DA","1","ProcedureExpirationDate"],"0x407A":["DA","1","ProcedureLastModifiedDate"],"0x407C":["TM","1-n","CalibrationTime"],"0x407E":["DA","1-n","CalibrationDate"],"0x4080":["SQ","1","ProbeDriveEquipmentSequence"],"0x4081":["CS","1","DriveType"],"0x4082":["LT","1","ProbeDriveNotes"],"0x4083":["SQ","1","DriveProbeSequence"],"0x4084":["DS","1","ProbeInductance"],"0x4085":["DS","1","ProbeResistance"],"0x4086":["SQ","1","ReceiveProbeSequence"],"0x4087":["SQ","1","ProbeDriveSettingsSequence"],"0x4088":["DS","1","BridgeResistors"],"0x4089":["DS","1","ProbeOrientationAngle"],"0x408B":["DS","1","UserSelectedGainY"],"0x408C":["DS","1","UserSelectedPhase"],"0x408D":["DS","1","UserSelectedOffsetX"],"0x408E":["DS","1","UserSelectedOffsetY"],"0x4091":["SQ","1","ChannelSettingsSequence"],"0x4092":["DS","1","ChannelThreshold"],"0x409A":["SQ","1","ScannerSettingsSequence"],"0x409B":["ST","1","ScanProcedure"],"0x409C":["DS","1","TranslationRateX"],"0x409D":["DS","1","TranslationRateY"],"0x409F":["DS","1","ChannelOverlap"],"0x40A0":["LO","1-n","ImageQualityIndicatorType"],"0x40A1":["LO","1-n","ImageQualityIndicatorMaterial"],"0x40A2":["LO","1-n","ImageQualityIndicatorSize"],"0x5002":["IS","1","LINACEnergy"],"0x5004":["IS","1","LINACOutput"],"0x5100":["US","1","ActiveAperture"],"0x5101":["DS","1","TotalAperture"],"0x5102":["DS","1","ApertureElevation"],"0x5103":["DS","1","MainLobeAngle"],"0x5104":["DS","1","MainRoofAngle"],"0x5105":["CS","1","ConnectorType"],"0x5106":["SH","1","WedgeModelNumber"],"0x5107":["DS","1","WedgeAngleFloat"],"0x5108":["DS","1","WedgeRoofAngle"],"0x5109":["CS","1","WedgeElement1Position"],"0x510A":["DS","1","WedgeMaterialVelocity"],"0x510B":["SH","1","WedgeMaterial"],"0x510C":["DS","1","WedgeOffsetZ"],"0x510D":["DS","1","WedgeOriginOffsetX"],"0x510E":["DS","1","WedgeTimeDelay"],"0x510F":["SH","1","WedgeName"],"0x5110":["SH","1","WedgeManufacturerName"],"0x5111":["LO","1","WedgeDescription"],"0x5112":["DS","1","NominalBeamAngle"],"0x5113":["DS","1","WedgeOffsetX"],"0x5114":["DS","1","WedgeOffsetY"],"0x5115":["DS","1","WedgeTotalLength"],"0x5116":["DS","1","WedgeInContactLength"],"0x5117":["DS","1","WedgeFrontGap"],"0x5118":["DS","1","WedgeTotalHeight"],"0x5119":["DS","1","WedgeFrontHeight"],"0x511A":["DS","1","WedgeRearHeight"],"0x511B":["DS","1","WedgeTotalWidth"],"0x511C":["DS","1","WedgeInContactWidth"],"0x511D":["DS","1","WedgeChamferHeight"],"0x511E":["CS","1","WedgeCurve"],"0x511F":["DS","1","RadiusAlongWedge"]},"0x0016":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["DS","1","WhitePoint"],"0x0002":["DS","3","PrimaryChromaticities"],"0x0003":["UT","1","BatteryLevel"],"0x0004":["DS","1","ExposureTimeInSeconds"],"0x0005":["DS","1","FNumber"],"0x0006":["IS","1","OECFRows"],"0x0007":["IS","1","OECFColumns"],"0x0008":["UC","1-n","OECFColumnNames"],"0x0009":["DS","1-n","OECFValues"],"0x000A":["IS","1","SpatialFrequencyResponseRows"],"0x000B":["IS","1","SpatialFrequencyResponseColumns"],"0x000C":["UC","1-n","SpatialFrequencyResponseColumnNames"],"0x000D":["DS","1-n","SpatialFrequencyResponseValues"],"0x000E":["IS","1","ColorFilterArrayPatternRows"],"0x000F":["IS","1","ColorFilterArrayPatternColumns"],"0x0010":["DS","1-n","ColorFilterArrayPatternValues"],"0x0011":["US","1","FlashFiringStatus"],"0x0012":["US","1","FlashReturnStatus"],"0x0013":["US","1","FlashMode"],"0x0014":["US","1","FlashFunctionPresent"],"0x0015":["US","1","FlashRedEyeMode"],"0x0016":["US","1","ExposureProgram"],"0x0017":["UT","1","SpectralSensitivity"],"0x0018":["IS","1","PhotographicSensitivity"],"0x0019":["IS","1","SelfTimerMode"],"0x001A":["US","1","SensitivityType"],"0x001B":["IS","1","StandardOutputSensitivity"],"0x001C":["IS","1","RecommendedExposureIndex"],"0x001D":["IS","1","ISOSpeed"],"0x001E":["IS","1","ISOSpeedLatitudeyyy"],"0x001F":["IS","1","ISOSpeedLatitudezzz"],"0x0020":["UT","1","EXIFVersion"],"0x0021":["DS","1","ShutterSpeedValue"],"0x0022":["DS","1","ApertureValue"],"0x0023":["DS","1","BrightnessValue"],"0x0024":["DS","1","ExposureBiasValue"],"0x0025":["DS","1","MaxApertureValue"],"0x0026":["DS","1","SubjectDistance"],"0x0027":["US","1","MeteringMode"],"0x0028":["US","1","LightSource"],"0x0029":["DS","1","FocalLength"],"0x002A":["IS","2-4","SubjectArea"],"0x002B":["OB","1","MakerNote"],"0x0030":["DS","1","Temperature"],"0x0031":["DS","1","Humidity"],"0x0032":["DS","1","Pressure"],"0x0033":["DS","1","WaterDepth"],"0x0034":["DS","1","Acceleration"],"0x0035":["DS","1","CameraElevationAngle"],"0x0036":["DS","1-2","FlashEnergy"],"0x0037":["IS","2","SubjectLocation"],"0x0038":["DS","1","PhotographicExposureIndex"],"0x0039":["US","1","SensingMethod"],"0x003A":["US","1","FileSource"],"0x003B":["US","1","SceneType"],"0x0041":["US","1","CustomRendered"],"0x0042":["US","1","ExposureMode"],"0x0043":["US","1","WhiteBalance"],"0x0044":["DS","1","DigitalZoomRatio"],"0x0045":["IS","1","FocalLengthIn35mmFilm"],"0x0046":["US","1","SceneCaptureType"],"0x0047":["US","1","GainControl"],"0x0048":["US","1","Contrast"],"0x0049":["US","1","Saturation"],"0x004A":["US","1","Sharpness"],"0x004B":["OB","1","DeviceSettingDescription"],"0x004C":["US","1","SubjectDistanceRange"],"0x004D":["UT","1","CameraOwnerName"],"0x004E":["DS","4","LensSpecification"],"0x004F":["UT","1","LensMake"],"0x0050":["UT","1","LensModel"],"0x0051":["UT","1","LensSerialNumber"],"0x0061":["CS","1","InteroperabilityIndex"],"0x0062":["OB","1","InteroperabilityVersion"],"0x0070":["OB","1","GPSVersionID"],"0x0071":["CS","1","GPSLatitudeRef"],"0x0072":["DS","3","GPSLatitude"],"0x0073":["CS","1","GPSLongitudeRef"],"0x0074":["DS","3","GPSLongitude"],"0x0075":["US","1","GPSAltitudeRef"],"0x0076":["DS","1","GPSAltitude"],"0x0077":["DT","1","GPSTimeStamp"],"0x0078":["UT","1","GPSSatellites"],"0x0079":["CS","1","GPSStatus"],"0x007A":["CS","1","GPSMeasureMode"],"0x007B":["DS","1","GPSDOP"],"0x007C":["CS","1","GPSSpeedRef"],"0x007D":["DS","1","GPSSpeed"],"0x007E":["CS","1","GPSTrackRef"],"0x007F":["DS","1","GPSTrack"],"0x0080":["CS","1","GPSImgDirectionRef"],"0x0081":["DS","1","GPSImgDirection"],"0x0082":["UT","1","GPSMapDatum"],"0x0083":["CS","1","GPSDestLatitudeRef"],"0x0084":["DS","3","GPSDestLatitude"],"0x0085":["CS","1","GPSDestLongitudeRef"],"0x0086":["DS","3","GPSDestLongitude"],"0x0087":["CS","1","GPSDestBearingRef"],"0x0088":["DS","1","GPSDestBearing"],"0x0089":["CS","1","GPSDestDistanceRef"],"0x008A":["DS","1","GPSDestDistance"],"0x008B":["OB","1","GPSProcessingMethod"],"0x008C":["OB","1","GPSAreaInformation"],"0x008D":["DT","1","GPSDateStamp"],"0x008E":["IS","1","GPSDifferential"],"0x1001":["CS","1","LightSourcePolarization"],"0x1002":["DS","1","EmitterColorTemperature"],"0x1003":["CS","1","ContactMethod"],"0x1004":["CS","1-n","ImmersionMedia"],"0x1005":["DS","1","OpticalMagnificationFactor"]},"0x0018":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["LO","1","ContrastBolusAgent"],"0x0012":["SQ","1","ContrastBolusAgentSequence"],"0x0013":["FL","1","ContrastBolusT1Relaxivity"],"0x0014":["SQ","1","ContrastBolusAdministrationRouteSequence"],"0x0015":["CS","1","BodyPartExamined"],"0x0020":["CS","1-n","ScanningSequence"],"0x0021":["CS","1-n","SequenceVariant"],"0x0022":["CS","1-n","ScanOptions"],"0x0023":["CS","1","MRAcquisitionType"],"0x0024":["SH","1","SequenceName"],"0x0025":["CS","1","AngioFlag"],"0x0026":["SQ","1","InterventionDrugInformationSequence"],"0x0027":["TM","1","InterventionDrugStopTime"],"0x0028":["DS","1","InterventionDrugDose"],"0x0029":["SQ","1","InterventionDrugCodeSequence"],"0x002A":["SQ","1","AdditionalDrugSequence"],"0x0030":["LO","1-n","Radionuclide"],"0x0031":["LO","1","Radiopharmaceutical"],"0x0032":["DS","1","EnergyWindowCenterline"],"0x0033":["DS","1-n","EnergyWindowTotalWidth"],"0x0034":["LO","1","InterventionDrugName"],"0x0035":["TM","1","InterventionDrugStartTime"],"0x0036":["SQ","1","InterventionSequence"],"0x0037":["CS","1","TherapyType"],"0x0038":["CS","1","InterventionStatus"],"0x0039":["CS","1","TherapyDescription"],"0x003A":["ST","1","InterventionDescription"],"0x0040":["IS","1","CineRate"],"0x0042":["CS","1","InitialCineRunState"],"0x0050":["DS","1","SliceThickness"],"0x0060":["DS","1","KVP"],"0x0061":["DS","1",""],"0x0070":["IS","1","CountsAccumulated"],"0x0071":["CS","1","AcquisitionTerminationCondition"],"0x0072":["DS","1","EffectiveDuration"],"0x0073":["CS","1","AcquisitionStartCondition"],"0x0074":["IS","1","AcquisitionStartConditionData"],"0x0075":["IS","1","AcquisitionTerminationConditionData"],"0x0080":["DS","1","RepetitionTime"],"0x0081":["DS","1","EchoTime"],"0x0082":["DS","1","InversionTime"],"0x0083":["DS","1","NumberOfAverages"],"0x0084":["DS","1","ImagingFrequency"],"0x0085":["SH","1","ImagedNucleus"],"0x0086":["IS","1-n","EchoNumbers"],"0x0087":["DS","1","MagneticFieldStrength"],"0x0088":["DS","1","SpacingBetweenSlices"],"0x0089":["IS","1","NumberOfPhaseEncodingSteps"],"0x0090":["DS","1","DataCollectionDiameter"],"0x0091":["IS","1","EchoTrainLength"],"0x0093":["DS","1","PercentSampling"],"0x0094":["DS","1","PercentPhaseFieldOfView"],"0x0095":["DS","1","PixelBandwidth"],"0x1000":["LO","1","DeviceSerialNumber"],"0x1002":["UI","1","DeviceUID"],"0x1003":["LO","1","DeviceID"],"0x1004":["LO","1","PlateID"],"0x1005":["LO","1","GeneratorID"],"0x1006":["LO","1","GridID"],"0x1007":["LO","1","CassetteID"],"0x1008":["LO","1","GantryID"],"0x1009":["UT","1","UniqueDeviceIdentifier"],"0x100A":["SQ","1","UDISequence"],"0x100B":["UI","1-n","ManufacturerDeviceClassUID"],"0x1010":["LO","1","SecondaryCaptureDeviceID"],"0x1011":["LO","1","HardcopyCreationDeviceID"],"0x1012":["DA","1","DateOfSecondaryCapture"],"0x1014":["TM","1","TimeOfSecondaryCapture"],"0x1016":["LO","1","SecondaryCaptureDeviceManufacturer"],"0x1017":["LO","1","HardcopyDeviceManufacturer"],"0x1018":["LO","1","SecondaryCaptureDeviceManufacturerModelName"],"0x1019":["LO","1-n","SecondaryCaptureDeviceSoftwareVersions"],"0x101A":["LO","1-n","HardcopyDeviceSoftwareVersion"],"0x101B":["LO","1","HardcopyDeviceManufacturerModelName"],"0x1020":["LO","1-n","SoftwareVersions"],"0x1022":["SH","1","VideoImageFormatAcquired"],"0x1023":["LO","1","DigitalImageFormatAcquired"],"0x1030":["LO","1","ProtocolName"],"0x1040":["LO","1","ContrastBolusRoute"],"0x1041":["DS","1","ContrastBolusVolume"],"0x1042":["TM","1","ContrastBolusStartTime"],"0x1043":["TM","1","ContrastBolusStopTime"],"0x1044":["DS","1","ContrastBolusTotalDose"],"0x1045":["IS","1","SyringeCounts"],"0x1046":["DS","1-n","ContrastFlowRate"],"0x1047":["DS","1-n","ContrastFlowDuration"],"0x1048":["CS","1","ContrastBolusIngredient"],"0x1049":["DS","1","ContrastBolusIngredientConcentration"],"0x1050":["DS","1","SpatialResolution"],"0x1060":["DS","1","TriggerTime"],"0x1061":["LO","1","TriggerSourceOrType"],"0x1062":["IS","1","NominalInterval"],"0x1063":["DS","1","FrameTime"],"0x1064":["LO","1","CardiacFramingType"],"0x1065":["DS","1-n","FrameTimeVector"],"0x1066":["DS","1","FrameDelay"],"0x1067":["DS","1","ImageTriggerDelay"],"0x1068":["DS","1","MultiplexGroupTimeOffset"],"0x1069":["DS","1","TriggerTimeOffset"],"0x106A":["CS","1","SynchronizationTrigger"],"0x106C":["US","2","SynchronizationChannel"],"0x106E":["UL","1","TriggerSamplePosition"],"0x1070":["LO","1","RadiopharmaceuticalRoute"],"0x1071":["DS","1","RadiopharmaceuticalVolume"],"0x1072":["TM","1","RadiopharmaceuticalStartTime"],"0x1073":["TM","1","RadiopharmaceuticalStopTime"],"0x1074":["DS","1","RadionuclideTotalDose"],"0x1075":["DS","1","RadionuclideHalfLife"],"0x1076":["DS","1","RadionuclidePositronFraction"],"0x1077":["DS","1","RadiopharmaceuticalSpecificActivity"],"0x1078":["DT","1","RadiopharmaceuticalStartDateTime"],"0x1079":["DT","1","RadiopharmaceuticalStopDateTime"],"0x1080":["CS","1","BeatRejectionFlag"],"0x1081":["IS","1","LowRRValue"],"0x1082":["IS","1","HighRRValue"],"0x1083":["IS","1","IntervalsAcquired"],"0x1084":["IS","1","IntervalsRejected"],"0x1085":["LO","1","PVCRejection"],"0x1086":["IS","1","SkipBeats"],"0x1088":["IS","1","HeartRate"],"0x1090":["IS","1","CardiacNumberOfImages"],"0x1094":["IS","1","TriggerWindow"],"0x1100":["DS","1","ReconstructionDiameter"],"0x1110":["DS","1","DistanceSourceToDetector"],"0x1111":["DS","1","DistanceSourceToPatient"],"0x1114":["DS","1","EstimatedRadiographicMagnificationFactor"],"0x1120":["DS","1","GantryDetectorTilt"],"0x1121":["DS","1","GantryDetectorSlew"],"0x1130":["DS","1","TableHeight"],"0x1131":["DS","1","TableTraverse"],"0x1134":["CS","1","TableMotion"],"0x1135":["DS","1-n","TableVerticalIncrement"],"0x1136":["DS","1-n","TableLateralIncrement"],"0x1137":["DS","1-n","TableLongitudinalIncrement"],"0x1138":["DS","1","TableAngle"],"0x113A":["CS","1","TableType"],"0x1140":["CS","1","RotationDirection"],"0x1141":["DS","1","AngularPosition"],"0x1142":["DS","1-n","RadialPosition"],"0x1143":["DS","1","ScanArc"],"0x1144":["DS","1","AngularStep"],"0x1145":["DS","1","CenterOfRotationOffset"],"0x1146":["DS","1-n","RotationOffset"],"0x1147":["CS","1","FieldOfViewShape"],"0x1149":["IS","1-2","FieldOfViewDimensions"],"0x1150":["IS","1","ExposureTime"],"0x1151":["IS","1","XRayTubeCurrent"],"0x1152":["IS","1","Exposure"],"0x1153":["IS","1","ExposureInuAs"],"0x1154":["DS","1","AveragePulseWidth"],"0x1155":["CS","1","RadiationSetting"],"0x1156":["CS","1","RectificationType"],"0x115A":["CS","1","RadiationMode"],"0x115E":["DS","1","ImageAndFluoroscopyAreaDoseProduct"],"0x1160":["SH","1","FilterType"],"0x1161":["LO","1-n","TypeOfFilters"],"0x1162":["DS","1","IntensifierSize"],"0x1164":["DS","2","ImagerPixelSpacing"],"0x1166":["CS","1-n","Grid"],"0x1170":["IS","1","GeneratorPower"],"0x1180":["SH","1","CollimatorGridName"],"0x1181":["CS","1","CollimatorType"],"0x1182":["IS","1-2","FocalDistance"],"0x1183":["DS","1-2","XFocusCenter"],"0x1184":["DS","1-2","YFocusCenter"],"0x1190":["DS","1-n","FocalSpots"],"0x1191":["CS","1","AnodeTargetMaterial"],"0x11A0":["DS","1","BodyPartThickness"],"0x11A2":["DS","1","CompressionForce"],"0x11A3":["DS","1","CompressionPressure"],"0x11A4":["LO","1","PaddleDescription"],"0x11A5":["DS","1","CompressionContactArea"],"0x11B0":["LO","1","AcquisitionMode"],"0x11B1":["LO","1","DoseModeName"],"0x11B2":["CS","1","AcquiredSubtractionMaskFlag"],"0x11B3":["CS","1","FluoroscopyPersistenceFlag"],"0x11B4":["CS","1","FluoroscopyLastImageHoldPersistenceFlag"],"0x11B5":["IS","1","UpperLimitNumberOfPersistentFluoroscopyFrames"],"0x11B6":["CS","1","ContrastBolusAutoInjectionTriggerFlag"],"0x11B7":["FD","1","ContrastBolusInjectionDelay"],"0x11B8":["SQ","1","XAAcquisitionPhaseDetailsSequence"],"0x11B9":["FD","1","XAAcquisitionFrameRate"],"0x11BA":["SQ","1","XAPlaneDetailsSequence"],"0x11BB":["LO","1","AcquisitionFieldOfViewLabel"],"0x11BC":["SQ","1","XRayFilterDetailsSequence"],"0x11BD":["FD","1","XAAcquisitionDuration"],"0x11BE":["CS","1","ReconstructionPipelineType"],"0x11BF":["SQ","1","ImageFilterDetailsSequence"],"0x11C0":["CS","1","AppliedMaskSubtractionFlag"],"0x11C1":["SQ","1","RequestedSeriesDescriptionCodeSequence"],"0x1200":["DA","1-n","DateOfLastCalibration"],"0x1201":["TM","1-n","TimeOfLastCalibration"],"0x1202":["DT","1","DateTimeOfLastCalibration"],"0x1203":["DT","1","CalibrationDateTime"],"0x1210":["SH","1-n","ConvolutionKernel"],"0x1240":["IS","1-n","UpperLowerPixelValues"],"0x1242":["IS","1","ActualFrameDuration"],"0x1243":["IS","1","CountRate"],"0x1244":["US","1","PreferredPlaybackSequencing"],"0x1250":["SH","1","ReceiveCoilName"],"0x1251":["SH","1","TransmitCoilName"],"0x1260":["SH","1","PlateType"],"0x1261":["LO","1","PhosphorType"],"0x1271":["FD","1","WaterEquivalentDiameter"],"0x1272":["SQ","1","WaterEquivalentDiameterCalculationMethodCodeSequence"],"0x1300":["DS","1","ScanVelocity"],"0x1301":["CS","1-n","WholeBodyTechnique"],"0x1302":["IS","1","ScanLength"],"0x1310":["US","4","AcquisitionMatrix"],"0x1312":["CS","1","InPlanePhaseEncodingDirection"],"0x1314":["DS","1","FlipAngle"],"0x1315":["CS","1","VariableFlipAngleFlag"],"0x1316":["DS","1","SAR"],"0x1318":["DS","1","dBdt"],"0x1320":["FL","1","B1rms"],"0x1400":["LO","1","AcquisitionDeviceProcessingDescription"],"0x1401":["LO","1","AcquisitionDeviceProcessingCode"],"0x1402":["CS","1","CassetteOrientation"],"0x1403":["CS","1","CassetteSize"],"0x1404":["US","1","ExposuresOnPlate"],"0x1405":["IS","1","RelativeXRayExposure"],"0x1411":["DS","1","ExposureIndex"],"0x1412":["DS","1","TargetExposureIndex"],"0x1413":["DS","1","DeviationIndex"],"0x1450":["DS","1","ColumnAngulation"],"0x1460":["DS","1","TomoLayerHeight"],"0x1470":["DS","1","TomoAngle"],"0x1480":["DS","1","TomoTime"],"0x1490":["CS","1","TomoType"],"0x1491":["CS","1","TomoClass"],"0x1495":["IS","1","NumberOfTomosynthesisSourceImages"],"0x1500":["CS","1","PositionerMotion"],"0x1508":["CS","1","PositionerType"],"0x1510":["DS","1","PositionerPrimaryAngle"],"0x1511":["DS","1","PositionerSecondaryAngle"],"0x1520":["DS","1-n","PositionerPrimaryAngleIncrement"],"0x1521":["DS","1-n","PositionerSecondaryAngleIncrement"],"0x1530":["DS","1","DetectorPrimaryAngle"],"0x1531":["DS","1","DetectorSecondaryAngle"],"0x1600":["CS","1-3","ShutterShape"],"0x1602":["IS","1","ShutterLeftVerticalEdge"],"0x1604":["IS","1","ShutterRightVerticalEdge"],"0x1606":["IS","1","ShutterUpperHorizontalEdge"],"0x1608":["IS","1","ShutterLowerHorizontalEdge"],"0x1610":["IS","2","CenterOfCircularShutter"],"0x1612":["IS","1","RadiusOfCircularShutter"],"0x1620":["IS","2-2n","VerticesOfThePolygonalShutter"],"0x1622":["US","1","ShutterPresentationValue"],"0x1623":["US","1","ShutterOverlayGroup"],"0x1624":["US","3","ShutterPresentationColorCIELabValue"],"0x1630":["CS","1","OutlineShapeType"],"0x1631":["FD","1","OutlineLeftVerticalEdge"],"0x1632":["FD","1","OutlineRightVerticalEdge"],"0x1633":["FD","1","OutlineUpperHorizontalEdge"],"0x1634":["FD","1","OutlineLowerHorizontalEdge"],"0x1635":["FD","2","CenterOfCircularOutline"],"0x1636":["FD","1","DiameterOfCircularOutline"],"0x1637":["UL","1","NumberOfPolygonalVertices"],"0x1638":["OF","1","VerticesOfThePolygonalOutline"],"0x1700":["CS","1-3","CollimatorShape"],"0x1702":["IS","1","CollimatorLeftVerticalEdge"],"0x1704":["IS","1","CollimatorRightVerticalEdge"],"0x1706":["IS","1","CollimatorUpperHorizontalEdge"],"0x1708":["IS","1","CollimatorLowerHorizontalEdge"],"0x1710":["IS","2","CenterOfCircularCollimator"],"0x1712":["IS","1","RadiusOfCircularCollimator"],"0x1720":["IS","2-2n","VerticesOfThePolygonalCollimator"],"0x1800":["CS","1","AcquisitionTimeSynchronized"],"0x1801":["SH","1","TimeSource"],"0x1802":["CS","1","TimeDistributionProtocol"],"0x1803":["LO","1","NTPSourceAddress"],"0x2001":["IS","1-n","PageNumberVector"],"0x2002":["SH","1-n","FrameLabelVector"],"0x2003":["DS","1-n","FramePrimaryAngleVector"],"0x2004":["DS","1-n","FrameSecondaryAngleVector"],"0x2005":["DS","1-n","SliceLocationVector"],"0x2006":["SH","1-n","DisplayWindowLabelVector"],"0x2010":["DS","2","NominalScannedPixelSpacing"],"0x2020":["CS","1","DigitizingDeviceTransportDirection"],"0x2030":["DS","1","RotationOfScannedFilm"],"0x2041":["SQ","1","BiopsyTargetSequence"],"0x2042":["UI","1","TargetUID"],"0x2043":["FL","2","LocalizingCursorPosition"],"0x2044":["FL","3","CalculatedTargetPosition"],"0x2045":["SH","1","TargetLabel"],"0x2046":["FL","1","DisplayedZValue"],"0x3100":["CS","1","IVUSAcquisition"],"0x3101":["DS","1","IVUSPullbackRate"],"0x3102":["DS","1","IVUSGatedRate"],"0x3103":["IS","1","IVUSPullbackStartFrameNumber"],"0x3104":["IS","1","IVUSPullbackStopFrameNumber"],"0x3105":["IS","1-n","LesionNumber"],"0x4000":["LT","1","AcquisitionComments"],"0x5000":["SH","1-n","OutputPower"],"0x5010":["LO","1-n","TransducerData"],"0x5011":["SQ","1","TransducerIdentificationSequence"],"0x5012":["DS","1","FocusDepth"],"0x5020":["LO","1","ProcessingFunction"],"0x5021":["LO","1","PostprocessingFunction"],"0x5022":["DS","1","MechanicalIndex"],"0x5024":["DS","1","BoneThermalIndex"],"0x5026":["DS","1","CranialThermalIndex"],"0x5027":["DS","1","SoftTissueThermalIndex"],"0x5028":["DS","1","SoftTissueFocusThermalIndex"],"0x5029":["DS","1","SoftTissueSurfaceThermalIndex"],"0x5030":["DS","1","DynamicRange"],"0x5040":["DS","1","TotalGain"],"0x5050":["IS","1","DepthOfScanField"],"0x5100":["CS","1","PatientPosition"],"0x5101":["CS","1","ViewPosition"],"0x5104":["SQ","1","ProjectionEponymousNameCodeSequence"],"0x5210":["DS","6","ImageTransformationMatrix"],"0x5212":["DS","3","ImageTranslationVector"],"0x6000":["DS","1","Sensitivity"],"0x6011":["SQ","1","SequenceOfUltrasoundRegions"],"0x6012":["US","1","RegionSpatialFormat"],"0x6014":["US","1","RegionDataType"],"0x6016":["UL","1","RegionFlags"],"0x6018":["UL","1","RegionLocationMinX0"],"0x601A":["UL","1","RegionLocationMinY0"],"0x601C":["UL","1","RegionLocationMaxX1"],"0x601E":["UL","1","RegionLocationMaxY1"],"0x6020":["SL","1","ReferencePixelX0"],"0x6022":["SL","1","ReferencePixelY0"],"0x6024":["US","1","PhysicalUnitsXDirection"],"0x6026":["US","1","PhysicalUnitsYDirection"],"0x6028":["FD","1","ReferencePixelPhysicalValueX"],"0x602A":["FD","1","ReferencePixelPhysicalValueY"],"0x602C":["FD","1","PhysicalDeltaX"],"0x602E":["FD","1","PhysicalDeltaY"],"0x6030":["UL","1","TransducerFrequency"],"0x6031":["CS","1","TransducerType"],"0x6032":["UL","1","PulseRepetitionFrequency"],"0x6034":["FD","1","DopplerCorrectionAngle"],"0x6036":["FD","1","SteeringAngle"],"0x6038":["UL","1","DopplerSampleVolumeXPositionRetired"],"0x6039":["SL","1","DopplerSampleVolumeXPosition"],"0x603A":["UL","1","DopplerSampleVolumeYPositionRetired"],"0x603B":["SL","1","DopplerSampleVolumeYPosition"],"0x603C":["UL","1","TMLinePositionX0Retired"],"0x603D":["SL","1","TMLinePositionX0"],"0x603E":["UL","1","TMLinePositionY0Retired"],"0x603F":["SL","1","TMLinePositionY0"],"0x6040":["UL","1","TMLinePositionX1Retired"],"0x6041":["SL","1","TMLinePositionX1"],"0x6042":["UL","1","TMLinePositionY1Retired"],"0x6043":["SL","1","TMLinePositionY1"],"0x6044":["US","1","PixelComponentOrganization"],"0x6046":["UL","1","PixelComponentMask"],"0x6048":["UL","1","PixelComponentRangeStart"],"0x604A":["UL","1","PixelComponentRangeStop"],"0x604C":["US","1","PixelComponentPhysicalUnits"],"0x604E":["US","1","PixelComponentDataType"],"0x6050":["UL","1","NumberOfTableBreakPoints"],"0x6052":["UL","1-n","TableOfXBreakPoints"],"0x6054":["FD","1-n","TableOfYBreakPoints"],"0x6056":["UL","1","NumberOfTableEntries"],"0x6058":["UL","1-n","TableOfPixelValues"],"0x605A":["FL","1-n","TableOfParameterValues"],"0x6060":["FL","1-n","RWaveTimeVector"],"0x6070":["US","1","ActiveImageAreaOverlayGroup"],"0x7000":["CS","1","DetectorConditionsNominalFlag"],"0x7001":["DS","1","DetectorTemperature"],"0x7004":["CS","1","DetectorType"],"0x7005":["CS","1","DetectorConfiguration"],"0x7006":["LT","1","DetectorDescription"],"0x7008":["LT","1","DetectorMode"],"0x700A":["SH","1","DetectorID"],"0x700C":["DA","1","DateOfLastDetectorCalibration"],"0x700E":["TM","1","TimeOfLastDetectorCalibration"],"0x7010":["IS","1","ExposuresOnDetectorSinceLastCalibration"],"0x7011":["IS","1","ExposuresOnDetectorSinceManufactured"],"0x7012":["DS","1","DetectorTimeSinceLastExposure"],"0x7014":["DS","1","DetectorActiveTime"],"0x7016":["DS","1","DetectorActivationOffsetFromExposure"],"0x701A":["DS","2","DetectorBinning"],"0x7020":["DS","2","DetectorElementPhysicalSize"],"0x7022":["DS","2","DetectorElementSpacing"],"0x7024":["CS","1","DetectorActiveShape"],"0x7026":["DS","1-2","DetectorActiveDimensions"],"0x7028":["DS","2","DetectorActiveOrigin"],"0x702A":["LO","1","DetectorManufacturerName"],"0x702B":["LO","1","DetectorManufacturerModelName"],"0x7030":["DS","2","FieldOfViewOrigin"],"0x7032":["DS","1","FieldOfViewRotation"],"0x7034":["CS","1","FieldOfViewHorizontalFlip"],"0x7036":["FL","2","PixelDataAreaOriginRelativeToFOV"],"0x7038":["FL","1","PixelDataAreaRotationAngleRelativeToFOV"],"0x7040":["LT","1","GridAbsorbingMaterial"],"0x7041":["LT","1","GridSpacingMaterial"],"0x7042":["DS","1","GridThickness"],"0x7044":["DS","1","GridPitch"],"0x7046":["IS","2","GridAspectRatio"],"0x7048":["DS","1","GridPeriod"],"0x704C":["DS","1","GridFocalDistance"],"0x7050":["CS","1-n","FilterMaterial"],"0x7052":["DS","1-n","FilterThicknessMinimum"],"0x7054":["DS","1-n","FilterThicknessMaximum"],"0x7056":["FL","1-n","FilterBeamPathLengthMinimum"],"0x7058":["FL","1-n","FilterBeamPathLengthMaximum"],"0x7060":["CS","1","ExposureControlMode"],"0x7062":["LT","1","ExposureControlModeDescription"],"0x7064":["CS","1","ExposureStatus"],"0x7065":["DS","1","PhototimerSetting"],"0x8150":["DS","1","ExposureTimeInuS"],"0x8151":["DS","1","XRayTubeCurrentInuA"],"0x9004":["CS","1","ContentQualification"],"0x9005":["SH","1","PulseSequenceName"],"0x9006":["SQ","1","MRImagingModifierSequence"],"0x9008":["CS","1","EchoPulseSequence"],"0x9009":["CS","1","InversionRecovery"],"0x9010":["CS","1","FlowCompensation"],"0x9011":["CS","1","MultipleSpinEcho"],"0x9012":["CS","1","MultiPlanarExcitation"],"0x9014":["CS","1","PhaseContrast"],"0x9015":["CS","1","TimeOfFlightContrast"],"0x9016":["CS","1","Spoiling"],"0x9017":["CS","1","SteadyStatePulseSequence"],"0x9018":["CS","1","EchoPlanarPulseSequence"],"0x9019":["FD","1","TagAngleFirstAxis"],"0x9020":["CS","1","MagnetizationTransfer"],"0x9021":["CS","1","T2Preparation"],"0x9022":["CS","1","BloodSignalNulling"],"0x9024":["CS","1","SaturationRecovery"],"0x9025":["CS","1","SpectrallySelectedSuppression"],"0x9026":["CS","1","SpectrallySelectedExcitation"],"0x9027":["CS","1","SpatialPresaturation"],"0x9028":["CS","1","Tagging"],"0x9029":["CS","1","OversamplingPhase"],"0x9030":["FD","1","TagSpacingFirstDimension"],"0x9032":["CS","1","GeometryOfKSpaceTraversal"],"0x9033":["CS","1","SegmentedKSpaceTraversal"],"0x9034":["CS","1","RectilinearPhaseEncodeReordering"],"0x9035":["FD","1","TagThickness"],"0x9036":["CS","1","PartialFourierDirection"],"0x9037":["CS","1","CardiacSynchronizationTechnique"],"0x9041":["LO","1","ReceiveCoilManufacturerName"],"0x9042":["SQ","1","MRReceiveCoilSequence"],"0x9043":["CS","1","ReceiveCoilType"],"0x9044":["CS","1","QuadratureReceiveCoil"],"0x9045":["SQ","1","MultiCoilDefinitionSequence"],"0x9046":["LO","1","MultiCoilConfiguration"],"0x9047":["SH","1","MultiCoilElementName"],"0x9048":["CS","1","MultiCoilElementUsed"],"0x9049":["SQ","1","MRTransmitCoilSequence"],"0x9050":["LO","1","TransmitCoilManufacturerName"],"0x9051":["CS","1","TransmitCoilType"],"0x9052":["FD","1-2","SpectralWidth"],"0x9053":["FD","1-2","ChemicalShiftReference"],"0x9054":["CS","1","VolumeLocalizationTechnique"],"0x9058":["US","1","MRAcquisitionFrequencyEncodingSteps"],"0x9059":["CS","1","Decoupling"],"0x9060":["CS","1-2","DecoupledNucleus"],"0x9061":["FD","1-2","DecouplingFrequency"],"0x9062":["CS","1","DecouplingMethod"],"0x9063":["FD","1-2","DecouplingChemicalShiftReference"],"0x9064":["CS","1","KSpaceFiltering"],"0x9065":["CS","1-2","TimeDomainFiltering"],"0x9066":["US","1-2","NumberOfZeroFills"],"0x9067":["CS","1","BaselineCorrection"],"0x9069":["FD","1","ParallelReductionFactorInPlane"],"0x9070":["FD","1","CardiacRRIntervalSpecified"],"0x9073":["FD","1","AcquisitionDuration"],"0x9074":["DT","1","FrameAcquisitionDateTime"],"0x9075":["CS","1","DiffusionDirectionality"],"0x9076":["SQ","1","DiffusionGradientDirectionSequence"],"0x9077":["CS","1","ParallelAcquisition"],"0x9078":["CS","1","ParallelAcquisitionTechnique"],"0x9079":["FD","1-n","InversionTimes"],"0x9080":["ST","1","MetaboliteMapDescription"],"0x9081":["CS","1","PartialFourier"],"0x9082":["FD","1","EffectiveEchoTime"],"0x9083":["SQ","1","MetaboliteMapCodeSequence"],"0x9084":["SQ","1","ChemicalShiftSequence"],"0x9085":["CS","1","CardiacSignalSource"],"0x9087":["FD","1","DiffusionBValue"],"0x9089":["FD","3","DiffusionGradientOrientation"],"0x9090":["FD","3","VelocityEncodingDirection"],"0x9091":["FD","1","VelocityEncodingMinimumValue"],"0x9092":["SQ","1","VelocityEncodingAcquisitionSequence"],"0x9093":["US","1","NumberOfKSpaceTrajectories"],"0x9094":["CS","1","CoverageOfKSpace"],"0x9095":["UL","1","SpectroscopyAcquisitionPhaseRows"],"0x9096":["FD","1","ParallelReductionFactorInPlaneRetired"],"0x9098":["FD","1-2","TransmitterFrequency"],"0x9100":["CS","1-2","ResonantNucleus"],"0x9101":["CS","1","FrequencyCorrection"],"0x9103":["SQ","1","MRSpectroscopyFOVGeometrySequence"],"0x9104":["FD","1","SlabThickness"],"0x9105":["FD","3","SlabOrientation"],"0x9106":["FD","3","MidSlabPosition"],"0x9107":["SQ","1","MRSpatialSaturationSequence"],"0x9112":["SQ","1","MRTimingAndRelatedParametersSequence"],"0x9114":["SQ","1","MREchoSequence"],"0x9115":["SQ","1","MRModifierSequence"],"0x9117":["SQ","1","MRDiffusionSequence"],"0x9118":["SQ","1","CardiacSynchronizationSequence"],"0x9119":["SQ","1","MRAveragesSequence"],"0x9125":["SQ","1","MRFOVGeometrySequence"],"0x9126":["SQ","1","VolumeLocalizationSequence"],"0x9127":["UL","1","SpectroscopyAcquisitionDataColumns"],"0x9147":["CS","1","DiffusionAnisotropyType"],"0x9151":["DT","1","FrameReferenceDateTime"],"0x9152":["SQ","1","MRMetaboliteMapSequence"],"0x9155":["FD","1","ParallelReductionFactorOutOfPlane"],"0x9159":["UL","1","SpectroscopyAcquisitionOutOfPlanePhaseSteps"],"0x9166":["CS","1","BulkMotionStatus"],"0x9168":["FD","1","ParallelReductionFactorSecondInPlane"],"0x9169":["CS","1","CardiacBeatRejectionTechnique"],"0x9170":["CS","1","RespiratoryMotionCompensationTechnique"],"0x9171":["CS","1","RespiratorySignalSource"],"0x9172":["CS","1","BulkMotionCompensationTechnique"],"0x9173":["CS","1","BulkMotionSignalSource"],"0x9174":["CS","1","ApplicableSafetyStandardAgency"],"0x9175":["LO","1","ApplicableSafetyStandardDescription"],"0x9176":["SQ","1","OperatingModeSequence"],"0x9177":["CS","1","OperatingModeType"],"0x9178":["CS","1","OperatingMode"],"0x9179":["CS","1","SpecificAbsorptionRateDefinition"],"0x9180":["CS","1","GradientOutputType"],"0x9181":["FD","1","SpecificAbsorptionRateValue"],"0x9182":["FD","1","GradientOutput"],"0x9183":["CS","1","FlowCompensationDirection"],"0x9184":["FD","1","TaggingDelay"],"0x9185":["ST","1","RespiratoryMotionCompensationTechniqueDescription"],"0x9186":["SH","1","RespiratorySignalSourceID"],"0x9195":["FD","1","ChemicalShiftMinimumIntegrationLimitInHz"],"0x9196":["FD","1","ChemicalShiftMaximumIntegrationLimitInHz"],"0x9197":["SQ","1","MRVelocityEncodingSequence"],"0x9198":["CS","1","FirstOrderPhaseCorrection"],"0x9199":["CS","1","WaterReferencedPhaseCorrection"],"0x9200":["CS","1","MRSpectroscopyAcquisitionType"],"0x9214":["CS","1","RespiratoryCyclePosition"],"0x9217":["FD","1","VelocityEncodingMaximumValue"],"0x9218":["FD","1","TagSpacingSecondDimension"],"0x9219":["SS","1","TagAngleSecondAxis"],"0x9220":["FD","1","FrameAcquisitionDuration"],"0x9226":["SQ","1","MRImageFrameTypeSequence"],"0x9227":["SQ","1","MRSpectroscopyFrameTypeSequence"],"0x9231":["US","1","MRAcquisitionPhaseEncodingStepsInPlane"],"0x9232":["US","1","MRAcquisitionPhaseEncodingStepsOutOfPlane"],"0x9234":["UL","1","SpectroscopyAcquisitionPhaseColumns"],"0x9236":["CS","1","CardiacCyclePosition"],"0x9239":["SQ","1","SpecificAbsorptionRateSequence"],"0x9240":["US","1","RFEchoTrainLength"],"0x9241":["US","1","GradientEchoTrainLength"],"0x9250":["CS","1","ArterialSpinLabelingContrast"],"0x9251":["SQ","1","MRArterialSpinLabelingSequence"],"0x9252":["LO","1","ASLTechniqueDescription"],"0x9253":["US","1","ASLSlabNumber"],"0x9254":["FD","1","ASLSlabThickness"],"0x9255":["FD","3","ASLSlabOrientation"],"0x9256":["FD","3","ASLMidSlabPosition"],"0x9257":["CS","1","ASLContext"],"0x9258":["UL","1","ASLPulseTrainDuration"],"0x9259":["CS","1","ASLCrusherFlag"],"0x925A":["FD","1","ASLCrusherFlowLimit"],"0x925B":["LO","1","ASLCrusherDescription"],"0x925C":["CS","1","ASLBolusCutoffFlag"],"0x925D":["SQ","1","ASLBolusCutoffTimingSequence"],"0x925E":["LO","1","ASLBolusCutoffTechnique"],"0x925F":["UL","1","ASLBolusCutoffDelayTime"],"0x9260":["SQ","1","ASLSlabSequence"],"0x9295":["FD","1","ChemicalShiftMinimumIntegrationLimitInppm"],"0x9296":["FD","1","ChemicalShiftMaximumIntegrationLimitInppm"],"0x9297":["CS","1","WaterReferenceAcquisition"],"0x9298":["IS","1","EchoPeakPosition"],"0x9301":["SQ","1","CTAcquisitionTypeSequence"],"0x9302":["CS","1","AcquisitionType"],"0x9303":["FD","1","TubeAngle"],"0x9304":["SQ","1","CTAcquisitionDetailsSequence"],"0x9305":["FD","1","RevolutionTime"],"0x9306":["FD","1","SingleCollimationWidth"],"0x9307":["FD","1","TotalCollimationWidth"],"0x9308":["SQ","1","CTTableDynamicsSequence"],"0x9309":["FD","1","TableSpeed"],"0x9310":["FD","1","TableFeedPerRotation"],"0x9311":["FD","1","SpiralPitchFactor"],"0x9312":["SQ","1","CTGeometrySequence"],"0x9313":["FD","3","DataCollectionCenterPatient"],"0x9314":["SQ","1","CTReconstructionSequence"],"0x9315":["CS","1","ReconstructionAlgorithm"],"0x9316":["CS","1","ConvolutionKernelGroup"],"0x9317":["FD","2","ReconstructionFieldOfView"],"0x9318":["FD","3","ReconstructionTargetCenterPatient"],"0x9319":["FD","1","ReconstructionAngle"],"0x9320":["SH","1","ImageFilter"],"0x9321":["SQ","1","CTExposureSequence"],"0x9322":["FD","2","ReconstructionPixelSpacing"],"0x9323":["CS","1-n","ExposureModulationType"],"0x9324":["FD","1","EstimatedDoseSaving"],"0x9325":["SQ","1","CTXRayDetailsSequence"],"0x9326":["SQ","1","CTPositionSequence"],"0x9327":["FD","1","TablePosition"],"0x9328":["FD","1","ExposureTimeInms"],"0x9329":["SQ","1","CTImageFrameTypeSequence"],"0x9330":["FD","1","XRayTubeCurrentInmA"],"0x9332":["FD","1","ExposureInmAs"],"0x9333":["CS","1","ConstantVolumeFlag"],"0x9334":["CS","1","FluoroscopyFlag"],"0x9335":["FD","1","DistanceSourceToDataCollectionCenter"],"0x9337":["US","1","ContrastBolusAgentNumber"],"0x9338":["SQ","1","ContrastBolusIngredientCodeSequence"],"0x9340":["SQ","1","ContrastAdministrationProfileSequence"],"0x9341":["SQ","1","ContrastBolusUsageSequence"],"0x9342":["CS","1","ContrastBolusAgentAdministered"],"0x9343":["CS","1","ContrastBolusAgentDetected"],"0x9344":["CS","1","ContrastBolusAgentPhase"],"0x9345":["FD","1","CTDIvol"],"0x9346":["SQ","1","CTDIPhantomTypeCodeSequence"],"0x9351":["FL","1","CalciumScoringMassFactorPatient"],"0x9352":["FL","3","CalciumScoringMassFactorDevice"],"0x9353":["FL","1","EnergyWeightingFactor"],"0x9360":["SQ","1","CTAdditionalXRaySourceSequence"],"0x9361":["CS","1","MultienergyCTAcquisition"],"0x9362":["SQ","1","MultienergyCTAcquisitionSequence"],"0x9363":["SQ","1","MultienergyCTProcessingSequence"],"0x9364":["SQ","1","MultienergyCTCharacteristicsSequence"],"0x9365":["SQ","1","MultienergyCTXRaySourceSequence"],"0x9366":["US","1","XRaySourceIndex"],"0x9367":["UC","1","XRaySourceID"],"0x9368":["CS","1","MultienergySourceTechnique"],"0x9369":["DT","1","SourceStartDateTime"],"0x936A":["DT","1","SourceEndDateTime"],"0x936B":["US","1","SwitchingPhaseNumber"],"0x936C":["DS","1","SwitchingPhaseNominalDuration"],"0x936D":["DS","1","SwitchingPhaseTransitionDuration"],"0x936E":["DS","1","EffectiveBinEnergy"],"0x936F":["SQ","1","MultienergyCTXRayDetectorSequence"],"0x9370":["US","1","XRayDetectorIndex"],"0x9371":["UC","1","XRayDetectorID"],"0x9372":["CS","1","MultienergyDetectorType"],"0x9373":["ST","1","XRayDetectorLabel"],"0x9374":["DS","1","NominalMaxEnergy"],"0x9375":["DS","1","NominalMinEnergy"],"0x9376":["US","1-n","ReferencedXRayDetectorIndex"],"0x9377":["US","1-n","ReferencedXRaySourceIndex"],"0x9378":["US","1-n","ReferencedPathIndex"],"0x9379":["SQ","1","MultienergyCTPathSequence"],"0x937A":["US","1","MultienergyCTPathIndex"],"0x937B":["UT","1","MultienergyAcquisitionDescription"],"0x937C":["FD","1","MonoenergeticEnergyEquivalent"],"0x937D":["SQ","1","MaterialCodeSequence"],"0x937E":["CS","1","DecompositionMethod"],"0x937F":["UT","1","DecompositionDescription"],"0x9380":["SQ","1","DecompositionAlgorithmIdentificationSequence"],"0x9381":["SQ","1","DecompositionMaterialSequence"],"0x9382":["SQ","1","MaterialAttenuationSequence"],"0x9383":["DS","1","PhotonEnergy"],"0x9384":["DS","1","XRayMassAttenuationCoefficient"],"0x9401":["SQ","1","ProjectionPixelCalibrationSequence"],"0x9402":["FL","1","DistanceSourceToIsocenter"],"0x9403":["FL","1","DistanceObjectToTableTop"],"0x9404":["FL","2","ObjectPixelSpacingInCenterOfBeam"],"0x9405":["SQ","1","PositionerPositionSequence"],"0x9406":["SQ","1","TablePositionSequence"],"0x9407":["SQ","1","CollimatorShapeSequence"],"0x9410":["CS","1","PlanesInAcquisition"],"0x9412":["SQ","1","XAXRFFrameCharacteristicsSequence"],"0x9417":["SQ","1","FrameAcquisitionSequence"],"0x9420":["CS","1","XRayReceptorType"],"0x9423":["LO","1","AcquisitionProtocolName"],"0x9424":["LT","1","AcquisitionProtocolDescription"],"0x9425":["CS","1","ContrastBolusIngredientOpaque"],"0x9426":["FL","1","DistanceReceptorPlaneToDetectorHousing"],"0x9427":["CS","1","IntensifierActiveShape"],"0x9428":["FL","1-2","IntensifierActiveDimensions"],"0x9429":["FL","2","PhysicalDetectorSize"],"0x9430":["FL","2","PositionOfIsocenterProjection"],"0x9432":["SQ","1","FieldOfViewSequence"],"0x9433":["LO","1","FieldOfViewDescription"],"0x9434":["SQ","1","ExposureControlSensingRegionsSequence"],"0x9435":["CS","1","ExposureControlSensingRegionShape"],"0x9436":["SS","1","ExposureControlSensingRegionLeftVerticalEdge"],"0x9437":["SS","1","ExposureControlSensingRegionRightVerticalEdge"],"0x9438":["SS","1","ExposureControlSensingRegionUpperHorizontalEdge"],"0x9439":["SS","1","ExposureControlSensingRegionLowerHorizontalEdge"],"0x9440":["SS","2","CenterOfCircularExposureControlSensingRegion"],"0x9441":["US","1","RadiusOfCircularExposureControlSensingRegion"],"0x9442":["SS","2-n","VerticesOfThePolygonalExposureControlSensingRegion"],"0x9445":["","",""],"0x9447":["FL","1","ColumnAngulationPatient"],"0x9449":["FL","1","BeamAngle"],"0x9451":["SQ","1","FrameDetectorParametersSequence"],"0x9452":["FL","1","CalculatedAnatomyThickness"],"0x9455":["SQ","1","CalibrationSequence"],"0x9456":["SQ","1","ObjectThicknessSequence"],"0x9457":["CS","1","PlaneIdentification"],"0x9461":["FL","1-2","FieldOfViewDimensionsInFloat"],"0x9462":["SQ","1","IsocenterReferenceSystemSequence"],"0x9463":["FL","1","PositionerIsocenterPrimaryAngle"],"0x9464":["FL","1","PositionerIsocenterSecondaryAngle"],"0x9465":["FL","1","PositionerIsocenterDetectorRotationAngle"],"0x9466":["FL","1","TableXPositionToIsocenter"],"0x9467":["FL","1","TableYPositionToIsocenter"],"0x9468":["FL","1","TableZPositionToIsocenter"],"0x9469":["FL","1","TableHorizontalRotationAngle"],"0x9470":["FL","1","TableHeadTiltAngle"],"0x9471":["FL","1","TableCradleTiltAngle"],"0x9472":["SQ","1","FrameDisplayShutterSequence"],"0x9473":["FL","1","AcquiredImageAreaDoseProduct"],"0x9474":["CS","1","CArmPositionerTabletopRelationship"],"0x9476":["SQ","1","XRayGeometrySequence"],"0x9477":["SQ","1","IrradiationEventIdentificationSequence"],"0x9504":["SQ","1","XRay3DFrameTypeSequence"],"0x9506":["SQ","1","ContributingSourcesSequence"],"0x9507":["SQ","1","XRay3DAcquisitionSequence"],"0x9508":["FL","1","PrimaryPositionerScanArc"],"0x9509":["FL","1","SecondaryPositionerScanArc"],"0x9510":["FL","1","PrimaryPositionerScanStartAngle"],"0x9511":["FL","1","SecondaryPositionerScanStartAngle"],"0x9514":["FL","1","PrimaryPositionerIncrement"],"0x9515":["FL","1","SecondaryPositionerIncrement"],"0x9516":["DT","1","StartAcquisitionDateTime"],"0x9517":["DT","1","EndAcquisitionDateTime"],"0x9518":["SS","1","PrimaryPositionerIncrementSign"],"0x9519":["SS","1","SecondaryPositionerIncrementSign"],"0x9524":["LO","1","ApplicationName"],"0x9525":["LO","1","ApplicationVersion"],"0x9526":["LO","1","ApplicationManufacturer"],"0x9527":["CS","1","AlgorithmType"],"0x9528":["LO","1","AlgorithmDescription"],"0x9530":["SQ","1","XRay3DReconstructionSequence"],"0x9531":["LO","1","ReconstructionDescription"],"0x9538":["SQ","1","PerProjectionAcquisitionSequence"],"0x9541":["SQ","1","DetectorPositionSequence"],"0x9542":["SQ","1","XRayAcquisitionDoseSequence"],"0x9543":["FD","1","XRaySourceIsocenterPrimaryAngle"],"0x9544":["FD","1","XRaySourceIsocenterSecondaryAngle"],"0x9545":["FD","1","BreastSupportIsocenterPrimaryAngle"],"0x9546":["FD","1","BreastSupportIsocenterSecondaryAngle"],"0x9547":["FD","1","BreastSupportXPositionToIsocenter"],"0x9548":["FD","1","BreastSupportYPositionToIsocenter"],"0x9549":["FD","1","BreastSupportZPositionToIsocenter"],"0x9550":["FD","1","DetectorIsocenterPrimaryAngle"],"0x9551":["FD","1","DetectorIsocenterSecondaryAngle"],"0x9552":["FD","1","DetectorXPositionToIsocenter"],"0x9553":["FD","1","DetectorYPositionToIsocenter"],"0x9554":["FD","1","DetectorZPositionToIsocenter"],"0x9555":["SQ","1","XRayGridSequence"],"0x9556":["SQ","1","XRayFilterSequence"],"0x9557":["FD","3","DetectorActiveAreaTLHCPosition"],"0x9558":["FD","6","DetectorActiveAreaOrientation"],"0x9559":["CS","1","PositionerPrimaryAngleDirection"],"0x9601":["SQ","1","DiffusionBMatrixSequence"],"0x9602":["FD","1","DiffusionBValueXX"],"0x9603":["FD","1","DiffusionBValueXY"],"0x9604":["FD","1","DiffusionBValueXZ"],"0x9605":["FD","1","DiffusionBValueYY"],"0x9606":["FD","1","DiffusionBValueYZ"],"0x9607":["FD","1","DiffusionBValueZZ"],"0x9621":["SQ","1","FunctionalMRSequence"],"0x9622":["CS","1","FunctionalSettlingPhaseFramesPresent"],"0x9623":["DT","1","FunctionalSyncPulse"],"0x9624":["CS","1","SettlingPhaseFrame"],"0x9701":["DT","1","DecayCorrectionDateTime"],"0x9715":["FD","1","StartDensityThreshold"],"0x9716":["FD","1","StartRelativeDensityDifferenceThreshold"],"0x9717":["FD","1","StartCardiacTriggerCountThreshold"],"0x9718":["FD","1","StartRespiratoryTriggerCountThreshold"],"0x9719":["FD","1","TerminationCountsThreshold"],"0x9720":["FD","1","TerminationDensityThreshold"],"0x9721":["FD","1","TerminationRelativeDensityThreshold"],"0x9722":["FD","1","TerminationTimeThreshold"],"0x9723":["FD","1","TerminationCardiacTriggerCountThreshold"],"0x9724":["FD","1","TerminationRespiratoryTriggerCountThreshold"],"0x9725":["CS","1","DetectorGeometry"],"0x9726":["FD","1","TransverseDetectorSeparation"],"0x9727":["FD","1","AxialDetectorDimension"],"0x9729":["US","1","RadiopharmaceuticalAgentNumber"],"0x9732":["SQ","1","PETFrameAcquisitionSequence"],"0x9733":["SQ","1","PETDetectorMotionDetailsSequence"],"0x9734":["SQ","1","PETTableDynamicsSequence"],"0x9735":["SQ","1","PETPositionSequence"],"0x9736":["SQ","1","PETFrameCorrectionFactorsSequence"],"0x9737":["SQ","1","RadiopharmaceuticalUsageSequence"],"0x9738":["CS","1","AttenuationCorrectionSource"],"0x9739":["US","1","NumberOfIterations"],"0x9740":["US","1","NumberOfSubsets"],"0x9749":["SQ","1","PETReconstructionSequence"],"0x9751":["SQ","1","PETFrameTypeSequence"],"0x9755":["CS","1","TimeOfFlightInformationUsed"],"0x9756":["CS","1","ReconstructionType"],"0x9758":["CS","1","DecayCorrected"],"0x9759":["CS","1","AttenuationCorrected"],"0x9760":["CS","1","ScatterCorrected"],"0x9761":["CS","1","DeadTimeCorrected"],"0x9762":["CS","1","GantryMotionCorrected"],"0x9763":["CS","1","PatientMotionCorrected"],"0x9764":["CS","1","CountLossNormalizationCorrected"],"0x9765":["CS","1","RandomsCorrected"],"0x9766":["CS","1","NonUniformRadialSamplingCorrected"],"0x9767":["CS","1","SensitivityCalibrated"],"0x9768":["CS","1","DetectorNormalizationCorrection"],"0x9769":["CS","1","IterativeReconstructionMethod"],"0x9770":["CS","1","AttenuationCorrectionTemporalRelationship"],"0x9771":["SQ","1","PatientPhysiologicalStateSequence"],"0x9772":["SQ","1","PatientPhysiologicalStateCodeSequence"],"0x9801":["FD","1-n","DepthsOfFocus"],"0x9803":["SQ","1","ExcludedIntervalsSequence"],"0x9804":["DT","1","ExclusionStartDateTime"],"0x9805":["FD","1","ExclusionDuration"],"0x9806":["SQ","1","USImageDescriptionSequence"],"0x9807":["SQ","1","ImageDataTypeSequence"],"0x9808":["CS","1","DataType"],"0x9809":["SQ","1","TransducerScanPatternCodeSequence"],"0x980B":["CS","1","AliasedDataType"],"0x980C":["CS","1","PositionMeasuringDeviceUsed"],"0x980D":["SQ","1","TransducerGeometryCodeSequence"],"0x980E":["SQ","1","TransducerBeamSteeringCodeSequence"],"0x980F":["SQ","1","TransducerApplicationCodeSequence"],"0x9810":["xs","1","ZeroVelocityPixelValue"],"0x9900":["LO","1","ReferenceLocationLabel"],"0x9901":["UT","1","ReferenceLocationDescription"],"0x9902":["SQ","1","ReferenceBasisCodeSequence"],"0x9903":["SQ","1","ReferenceGeometryCodeSequence"],"0x9904":["DS","1","OffsetDistance"],"0x9905":["CS","1","OffsetDirection"],"0x9906":["SQ","1","PotentialScheduledProtocolCodeSequence"],"0x9907":["SQ","1","PotentialRequestedProcedureCodeSequence"],"0x9908":["UC","1-n","PotentialReasonsForProcedure"],"0x9909":["SQ","1","PotentialReasonsForProcedureCodeSequence"],"0x990A":["UC","1-n","PotentialDiagnosticTasks"],"0x990B":["SQ","1","ContraindicationsCodeSequence"],"0x990C":["SQ","1","ReferencedDefinedProtocolSequence"],"0x990D":["SQ","1","ReferencedPerformedProtocolSequence"],"0x990E":["SQ","1","PredecessorProtocolSequence"],"0x990F":["UT","1","ProtocolPlanningInformation"],"0x9910":["UT","1","ProtocolDesignRationale"],"0x9911":["SQ","1","PatientSpecificationSequence"],"0x9912":["SQ","1","ModelSpecificationSequence"],"0x9913":["SQ","1","ParametersSpecificationSequence"],"0x9914":["SQ","1","InstructionSequence"],"0x9915":["US","1","InstructionIndex"],"0x9916":["LO","1","InstructionText"],"0x9917":["UT","1","InstructionDescription"],"0x9918":["CS","1","InstructionPerformedFlag"],"0x9919":["DT","1","InstructionPerformedDateTime"],"0x991A":["UT","1","InstructionPerformanceComment"],"0x991B":["SQ","1","PatientPositioningInstructionSequence"],"0x991C":["SQ","1","PositioningMethodCodeSequence"],"0x991D":["SQ","1","PositioningLandmarkSequence"],"0x991E":["UI","1","TargetFrameOfReferenceUID"],"0x991F":["SQ","1","AcquisitionProtocolElementSpecificationSequence"],"0x9920":["SQ","1","AcquisitionProtocolElementSequence"],"0x9921":["US","1","ProtocolElementNumber"],"0x9922":["LO","1","ProtocolElementName"],"0x9923":["UT","1","ProtocolElementCharacteristicsSummary"],"0x9924":["UT","1","ProtocolElementPurpose"],"0x9930":["CS","1","AcquisitionMotion"],"0x9931":["SQ","1","AcquisitionStartLocationSequence"],"0x9932":["SQ","1","AcquisitionEndLocationSequence"],"0x9933":["SQ","1","ReconstructionProtocolElementSpecificationSequence"],"0x9934":["SQ","1","ReconstructionProtocolElementSequence"],"0x9935":["SQ","1","StorageProtocolElementSpecificationSequence"],"0x9936":["SQ","1","StorageProtocolElementSequence"],"0x9937":["LO","1","RequestedSeriesDescription"],"0x9938":["US","1-n","SourceAcquisitionProtocolElementNumber"],"0x9939":["US","1-n","SourceAcquisitionBeamNumber"],"0x993A":["US","1-n","SourceReconstructionProtocolElementNumber"],"0x993B":["SQ","1","ReconstructionStartLocationSequence"],"0x993C":["SQ","1","ReconstructionEndLocationSequence"],"0x993D":["SQ","1","ReconstructionAlgorithmSequence"],"0x993E":["SQ","1","ReconstructionTargetCenterLocationSequence"],"0x9941":["UT","1","ImageFilterDescription"],"0x9942":["FD","1","CTDIvolNotificationTrigger"],"0x9943":["FD","1","DLPNotificationTrigger"],"0x9944":["CS","1","AutoKVPSelectionType"],"0x9945":["FD","1","AutoKVPUpperBound"],"0x9946":["FD","1","AutoKVPLowerBound"],"0x9947":["CS","1","ProtocolDefinedPatientPosition"],"0xA001":["SQ","1","ContributingEquipmentSequence"],"0xA002":["DT","1","ContributionDateTime"],"0xA003":["ST","1","ContributionDescription"]},"0x0020":{"0x0000":["UL","1","GenericGroupLength"],"0x000D":["UI","1","StudyInstanceUID"],"0x000E":["UI","1","SeriesInstanceUID"],"0x0010":["SH","1","StudyID"],"0x0011":["IS","1","SeriesNumber"],"0x0012":["IS","1","AcquisitionNumber"],"0x0013":["IS","1","InstanceNumber"],"0x0014":["IS","1","IsotopeNumber"],"0x0015":["IS","1","PhaseNumber"],"0x0016":["IS","1","IntervalNumber"],"0x0017":["IS","1","TimeSlotNumber"],"0x0018":["IS","1","AngleNumber"],"0x0019":["IS","1","ItemNumber"],"0x0020":["CS","2","PatientOrientation"],"0x0022":["IS","1","OverlayNumber"],"0x0024":["IS","1","CurveNumber"],"0x0026":["IS","1","LUTNumber"],"0x0030":["DS","3","ImagePosition"],"0x0032":["DS","3","ImagePositionPatient"],"0x0035":["DS","6","ImageOrientation"],"0x0037":["DS","6","ImageOrientationPatient"],"0x0050":["DS","1","Location"],"0x0052":["UI","1","FrameOfReferenceUID"],"0x0060":["CS","1","Laterality"],"0x0062":["CS","1","ImageLaterality"],"0x0070":["LO","1","ImageGeometryType"],"0x0080":["CS","1-n","MaskingImage"],"0x00AA":["IS","1","ReportNumber"],"0x0100":["IS","1","TemporalPositionIdentifier"],"0x0105":["IS","1","NumberOfTemporalPositions"],"0x0110":["DS","1","TemporalResolution"],"0x0200":["UI","1","SynchronizationFrameOfReferenceUID"],"0x0242":["UI","1","SOPInstanceUIDOfConcatenationSource"],"0x1000":["IS","1","SeriesInStudy"],"0x1001":["IS","1","AcquisitionsInSeries"],"0x1002":["IS","1","ImagesInAcquisition"],"0x1003":["IS","1","ImagesInSeries"],"0x1004":["IS","1","AcquisitionsInStudy"],"0x1005":["IS","1","ImagesInStudy"],"0x1020":["LO","1-n","Reference"],"0x103F":["LO","1","TargetPositionReferenceIndicator"],"0x1040":["LO","1","PositionReferenceIndicator"],"0x1041":["DS","1","SliceLocation"],"0x1070":["IS","1-n","OtherStudyNumbers"],"0x1200":["IS","1","NumberOfPatientRelatedStudies"],"0x1202":["IS","1","NumberOfPatientRelatedSeries"],"0x1204":["IS","1","NumberOfPatientRelatedInstances"],"0x1206":["IS","1","NumberOfStudyRelatedSeries"],"0x1208":["IS","1","NumberOfStudyRelatedInstances"],"0x1209":["IS","1","NumberOfSeriesRelatedInstances"],"0x3100":["CS","1-n","SourceImageIDs"],"0x3401":["CS","1","ModifyingDeviceID"],"0x3402":["CS","1","ModifiedImageID"],"0x3403":["DA","1","ModifiedImageDate"],"0x3404":["LO","1","ModifyingDeviceManufacturer"],"0x3405":["TM","1","ModifiedImageTime"],"0x3406":["LO","1","ModifiedImageDescription"],"0x4000":["LT","1","ImageComments"],"0x5000":["AT","1-n","OriginalImageIdentification"],"0x5002":["LO","1-n","OriginalImageIdentificationNomenclature"],"0x9056":["SH","1","StackID"],"0x9057":["UL","1","InStackPositionNumber"],"0x9071":["SQ","1","FrameAnatomySequence"],"0x9072":["CS","1","FrameLaterality"],"0x9111":["SQ","1","FrameContentSequence"],"0x9113":["SQ","1","PlanePositionSequence"],"0x9116":["SQ","1","PlaneOrientationSequence"],"0x9128":["UL","1","TemporalPositionIndex"],"0x9153":["FD","1","NominalCardiacTriggerDelayTime"],"0x9154":["FL","1","NominalCardiacTriggerTimePriorToRPeak"],"0x9155":["FL","1","ActualCardiacTriggerTimePriorToRPeak"],"0x9156":["US","1","FrameAcquisitionNumber"],"0x9157":["UL","1-n","DimensionIndexValues"],"0x9158":["LT","1","FrameComments"],"0x9161":["UI","1","ConcatenationUID"],"0x9162":["US","1","InConcatenationNumber"],"0x9163":["US","1","InConcatenationTotalNumber"],"0x9164":["UI","1","DimensionOrganizationUID"],"0x9165":["AT","1","DimensionIndexPointer"],"0x9167":["AT","1","FunctionalGroupPointer"],"0x9170":["SQ","1","UnassignedSharedConvertedAttributesSequence"],"0x9171":["SQ","1","UnassignedPerFrameConvertedAttributesSequence"],"0x9172":["SQ","1","ConversionSourceAttributesSequence"],"0x9213":["LO","1","DimensionIndexPrivateCreator"],"0x9221":["SQ","1","DimensionOrganizationSequence"],"0x9222":["SQ","1","DimensionIndexSequence"],"0x9228":["UL","1","ConcatenationFrameOffsetNumber"],"0x9238":["LO","1","FunctionalGroupPrivateCreator"],"0x9241":["FL","1","NominalPercentageOfCardiacPhase"],"0x9245":["FL","1","NominalPercentageOfRespiratoryPhase"],"0x9246":["FL","1","StartingRespiratoryAmplitude"],"0x9247":["CS","1","StartingRespiratoryPhase"],"0x9248":["FL","1","EndingRespiratoryAmplitude"],"0x9249":["CS","1","EndingRespiratoryPhase"],"0x9250":["CS","1","RespiratoryTriggerType"],"0x9251":["FD","1","RRIntervalTimeNominal"],"0x9252":["FD","1","ActualCardiacTriggerDelayTime"],"0x9253":["SQ","1","RespiratorySynchronizationSequence"],"0x9254":["FD","1","RespiratoryIntervalTime"],"0x9255":["FD","1","NominalRespiratoryTriggerDelayTime"],"0x9256":["FD","1","RespiratoryTriggerDelayThreshold"],"0x9257":["FD","1","ActualRespiratoryTriggerDelayTime"],"0x9301":["FD","3","ImagePositionVolume"],"0x9302":["FD","6","ImageOrientationVolume"],"0x9307":["CS","1","UltrasoundAcquisitionGeometry"],"0x9308":["FD","3","ApexPosition"],"0x9309":["FD","16","VolumeToTransducerMappingMatrix"],"0x930A":["FD","16","VolumeToTableMappingMatrix"],"0x930B":["CS","1","VolumeToTransducerRelationship"],"0x930C":["CS","1","PatientFrameOfReferenceSource"],"0x930D":["FD","1","TemporalPositionTimeOffset"],"0x930E":["SQ","1","PlanePositionVolumeSequence"],"0x930F":["SQ","1","PlaneOrientationVolumeSequence"],"0x9310":["SQ","1","TemporalPositionSequence"],"0x9311":["CS","1","DimensionOrganizationType"],"0x9312":["UI","1","VolumeFrameOfReferenceUID"],"0x9313":["UI","1","TableFrameOfReferenceUID"],"0x9421":["LO","1","DimensionDescriptionLabel"],"0x9450":["SQ","1","PatientOrientationInFrameSequence"],"0x9453":["LO","1","FrameLabel"],"0x9518":["US","1-n","AcquisitionIndex"],"0x9529":["SQ","1","ContributingSOPInstancesReferenceSequence"],"0x9536":["US","1","ReconstructionIndex"]},"0x0022":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["US","1","LightPathFilterPassThroughWavelength"],"0x0002":["US","2","LightPathFilterPassBand"],"0x0003":["US","1","ImagePathFilterPassThroughWavelength"],"0x0004":["US","2","ImagePathFilterPassBand"],"0x0005":["CS","1","PatientEyeMovementCommanded"],"0x0006":["SQ","1","PatientEyeMovementCommandCodeSequence"],"0x0007":["FL","1","SphericalLensPower"],"0x0008":["FL","1","CylinderLensPower"],"0x0009":["FL","1","CylinderAxis"],"0x000A":["FL","1","EmmetropicMagnification"],"0x000B":["FL","1","IntraOcularPressure"],"0x000C":["FL","1","HorizontalFieldOfView"],"0x000D":["CS","1","PupilDilated"],"0x000E":["FL","1","DegreeOfDilation"],"0x0010":["FL","1","StereoBaselineAngle"],"0x0011":["FL","1","StereoBaselineDisplacement"],"0x0012":["FL","1","StereoHorizontalPixelOffset"],"0x0013":["FL","1","StereoVerticalPixelOffset"],"0x0014":["FL","1","StereoRotation"],"0x0015":["SQ","1","AcquisitionDeviceTypeCodeSequence"],"0x0016":["SQ","1","IlluminationTypeCodeSequence"],"0x0017":["SQ","1","LightPathFilterTypeStackCodeSequence"],"0x0018":["SQ","1","ImagePathFilterTypeStackCodeSequence"],"0x0019":["SQ","1","LensesCodeSequence"],"0x001A":["SQ","1","ChannelDescriptionCodeSequence"],"0x001B":["SQ","1","RefractiveStateSequence"],"0x001C":["SQ","1","MydriaticAgentCodeSequence"],"0x001D":["SQ","1","RelativeImagePositionCodeSequence"],"0x001E":["FL","1","CameraAngleOfView"],"0x0020":["SQ","1","StereoPairsSequence"],"0x0021":["SQ","1","LeftImageSequence"],"0x0022":["SQ","1","RightImageSequence"],"0x0028":["CS","1","StereoPairsPresent"],"0x0030":["FL","1","AxialLengthOfTheEye"],"0x0031":["SQ","1","OphthalmicFrameLocationSequence"],"0x0032":["FL","2-2n","ReferenceCoordinates"],"0x0035":["FL","1","DepthSpatialResolution"],"0x0036":["FL","1","MaximumDepthDistortion"],"0x0037":["FL","1","AlongScanSpatialResolution"],"0x0038":["FL","1","MaximumAlongScanDistortion"],"0x0039":["CS","1","OphthalmicImageOrientation"],"0x0041":["FL","1","DepthOfTransverseImage"],"0x0042":["SQ","1","MydriaticAgentConcentrationUnitsSequence"],"0x0048":["FL","1","AcrossScanSpatialResolution"],"0x0049":["FL","1","MaximumAcrossScanDistortion"],"0x004E":["DS","1","MydriaticAgentConcentration"],"0x0055":["FL","1","IlluminationWaveLength"],"0x0056":["FL","1","IlluminationPower"],"0x0057":["FL","1","IlluminationBandwidth"],"0x0058":["SQ","1","MydriaticAgentSequence"],"0x1007":["SQ","1","OphthalmicAxialMeasurementsRightEyeSequence"],"0x1008":["SQ","1","OphthalmicAxialMeasurementsLeftEyeSequence"],"0x1009":["CS","1","OphthalmicAxialMeasurementsDeviceType"],"0x1010":["CS","1","OphthalmicAxialLengthMeasurementsType"],"0x1012":["SQ","1","OphthalmicAxialLengthSequence"],"0x1019":["FL","1","OphthalmicAxialLength"],"0x1024":["SQ","1","LensStatusCodeSequence"],"0x1025":["SQ","1","VitreousStatusCodeSequence"],"0x1028":["SQ","1","IOLFormulaCodeSequence"],"0x1029":["LO","1","IOLFormulaDetail"],"0x1033":["FL","1","KeratometerIndex"],"0x1035":["SQ","1","SourceOfOphthalmicAxialLengthCodeSequence"],"0x1036":["SQ","1","SourceOfCornealSizeDataCodeSequence"],"0x1037":["FL","1","TargetRefraction"],"0x1039":["CS","1","RefractiveProcedureOccurred"],"0x1040":["SQ","1","RefractiveSurgeryTypeCodeSequence"],"0x1044":["SQ","1","OphthalmicUltrasoundMethodCodeSequence"],"0x1045":["SQ","1","SurgicallyInducedAstigmatismSequence"],"0x1046":["CS","1","TypeOfOpticalCorrection"],"0x1047":["SQ","1","ToricIOLPowerSequence"],"0x1048":["SQ","1","PredictedToricErrorSequence"],"0x1049":["CS","1","PreSelectedForImplantation"],"0x104A":["SQ","1","ToricIOLPowerForExactEmmetropiaSequence"],"0x104B":["SQ","1","ToricIOLPowerForExactTargetRefractionSequence"],"0x1050":["SQ","1","OphthalmicAxialLengthMeasurementsSequence"],"0x1053":["FL","1","IOLPower"],"0x1054":["FL","1","PredictedRefractiveError"],"0x1059":["FL","1","OphthalmicAxialLengthVelocity"],"0x1065":["LO","1","LensStatusDescription"],"0x1066":["LO","1","VitreousStatusDescription"],"0x1090":["SQ","1","IOLPowerSequence"],"0x1092":["SQ","1","LensConstantSequence"],"0x1093":["LO","1","IOLManufacturer"],"0x1094":["LO","1","LensConstantDescription"],"0x1095":["LO","1","ImplantName"],"0x1096":["SQ","1","KeratometryMeasurementTypeCodeSequence"],"0x1097":["LO","1","ImplantPartNumber"],"0x1100":["SQ","1","ReferencedOphthalmicAxialMeasurementsSequence"],"0x1101":["SQ","1","OphthalmicAxialLengthMeasurementsSegmentNameCodeSequence"],"0x1103":["SQ","1","RefractiveErrorBeforeRefractiveSurgeryCodeSequence"],"0x1121":["FL","1","IOLPowerForExactEmmetropia"],"0x1122":["FL","1","IOLPowerForExactTargetRefraction"],"0x1125":["SQ","1","AnteriorChamberDepthDefinitionCodeSequence"],"0x1127":["SQ","1","LensThicknessSequence"],"0x1128":["SQ","1","AnteriorChamberDepthSequence"],"0x112A":["SQ","1","CalculationCommentSequence"],"0x112B":["CS","1","CalculationCommentType"],"0x112C":["LT","1","CalculationComment"],"0x1130":["FL","1","LensThickness"],"0x1131":["FL","1","AnteriorChamberDepth"],"0x1132":["SQ","1","SourceOfLensThicknessDataCodeSequence"],"0x1133":["SQ","1","SourceOfAnteriorChamberDepthDataCodeSequence"],"0x1134":["SQ","1","SourceOfRefractiveMeasurementsSequence"],"0x1135":["SQ","1","SourceOfRefractiveMeasurementsCodeSequence"],"0x1140":["CS","1","OphthalmicAxialLengthMeasurementModified"],"0x1150":["SQ","1","OphthalmicAxialLengthDataSourceCodeSequence"],"0x1153":["SQ","1","OphthalmicAxialLengthAcquisitionMethodCodeSequence"],"0x1155":["FL","1","SignalToNoiseRatio"],"0x1159":["LO","1","OphthalmicAxialLengthDataSourceDescription"],"0x1210":["SQ","1","OphthalmicAxialLengthMeasurementsTotalLengthSequence"],"0x1211":["SQ","1","OphthalmicAxialLengthMeasurementsSegmentalLengthSequence"],"0x1212":["SQ","1","OphthalmicAxialLengthMeasurementsLengthSummationSequence"],"0x1220":["SQ","1","UltrasoundOphthalmicAxialLengthMeasurementsSequence"],"0x1225":["SQ","1","OpticalOphthalmicAxialLengthMeasurementsSequence"],"0x1230":["SQ","1","UltrasoundSelectedOphthalmicAxialLengthSequence"],"0x1250":["SQ","1","OphthalmicAxialLengthSelectionMethodCodeSequence"],"0x1255":["SQ","1","OpticalSelectedOphthalmicAxialLengthSequence"],"0x1257":["SQ","1","SelectedSegmentalOphthalmicAxialLengthSequence"],"0x1260":["SQ","1","SelectedTotalOphthalmicAxialLengthSequence"],"0x1262":["SQ","1","OphthalmicAxialLengthQualityMetricSequence"],"0x1265":["SQ","1","OphthalmicAxialLengthQualityMetricTypeCodeSequence"],"0x1273":["LO","1","OphthalmicAxialLengthQualityMetricTypeDescription"],"0x1300":["SQ","1","IntraocularLensCalculationsRightEyeSequence"],"0x1310":["SQ","1","IntraocularLensCalculationsLeftEyeSequence"],"0x1330":["SQ","1","ReferencedOphthalmicAxialLengthMeasurementQCImageSequence"],"0x1415":["CS","1","OphthalmicMappingDeviceType"],"0x1420":["SQ","1","AcquisitionMethodCodeSequence"],"0x1423":["SQ","1","AcquisitionMethodAlgorithmSequence"],"0x1436":["SQ","1","OphthalmicThicknessMapTypeCodeSequence"],"0x1443":["SQ","1","OphthalmicThicknessMappingNormalsSequence"],"0x1445":["SQ","1","RetinalThicknessDefinitionCodeSequence"],"0x1450":["SQ","1","PixelValueMappingToCodedConceptSequence"],"0x1452":["xs","1","MappedPixelValue"],"0x1454":["LO","1","PixelValueMappingExplanation"],"0x1458":["SQ","1","OphthalmicThicknessMapQualityThresholdSequence"],"0x1460":["FL","1","OphthalmicThicknessMapThresholdQualityRating"],"0x1463":["FL","2","AnatomicStructureReferencePoint"],"0x1465":["SQ","1","RegistrationToLocalizerSequence"],"0x1466":["CS","1","RegisteredLocalizerUnits"],"0x1467":["FL","2","RegisteredLocalizerTopLeftHandCorner"],"0x1468":["FL","2","RegisteredLocalizerBottomRightHandCorner"],"0x1470":["SQ","1","OphthalmicThicknessMapQualityRatingSequence"],"0x1472":["SQ","1","RelevantOPTAttributesSequence"],"0x1512":["SQ","1","TransformationMethodCodeSequence"],"0x1513":["SQ","1","TransformationAlgorithmSequence"],"0x1515":["CS","1","OphthalmicAxialLengthMethod"],"0x1517":["FL","1","OphthalmicFOV"],"0x1518":["SQ","1","TwoDimensionalToThreeDimensionalMapSequence"],"0x1525":["SQ","1","WideFieldOphthalmicPhotographyQualityRatingSequence"],"0x1526":["SQ","1","WideFieldOphthalmicPhotographyQualityThresholdSequence"],"0x1527":["FL","1","WideFieldOphthalmicPhotographyThresholdQualityRating"],"0x1528":["FL","1","XCoordinatesCenterPixelViewAngle"],"0x1529":["FL","1","YCoordinatesCenterPixelViewAngle"],"0x1530":["UL","1","NumberOfMapPoints"],"0x1531":["OF","1","TwoDimensionalToThreeDimensionalMapData"],"0x1612":["SQ","1","DerivationAlgorithmSequence"],"0x1615":["SQ","1","OphthalmicImageTypeCodeSequence"],"0x1616":["LO","1","OphthalmicImageTypeDescription"],"0x1618":["SQ","1","ScanPatternTypeCodeSequence"],"0x1620":["SQ","1","ReferencedSurfaceMeshIdentificationSequence"],"0x1622":["CS","1","OphthalmicVolumetricPropertiesFlag"],"0x1624":["FL","1","OphthalmicAnatomicReferencePointXCoordinate"],"0x1626":["FL","1","OphthalmicAnatomicReferencePointYCoordinate"],"0x1628":["SQ","1","OphthalmicEnFaceImageQualityRatingSequence"],"0x1630":["DS","1","QualityThreshold"],"0x1640":["SQ","1","OCTBscanAnalysisAcquisitionParametersSequence"],"0x1642":["UL","1","NumberOfBscansPerFrame"],"0x1643":["FL","1","BscanSlabThickness"],"0x1644":["FL","1","DistanceBetweenBscanSlabs"],"0x1645":["FL","1","BscanCycleTime"],"0x1646":["FL","1-n","BscanCycleTimeVector"],"0x1649":["FL","1","AscanRate"],"0x1650":["FL","1","BscanRate"],"0x1658":["UL","1","SurfaceMeshZPixelOffset"]},"0x0024":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["FL","1","VisualFieldHorizontalExtent"],"0x0011":["FL","1","VisualFieldVerticalExtent"],"0x0012":["CS","1","VisualFieldShape"],"0x0016":["SQ","1","ScreeningTestModeCodeSequence"],"0x0018":["FL","1","MaximumStimulusLuminance"],"0x0020":["FL","1","BackgroundLuminance"],"0x0021":["SQ","1","StimulusColorCodeSequence"],"0x0024":["SQ","1","BackgroundIlluminationColorCodeSequence"],"0x0025":["FL","1","StimulusArea"],"0x0028":["FL","1","StimulusPresentationTime"],"0x0032":["SQ","1","FixationSequence"],"0x0033":["SQ","1","FixationMonitoringCodeSequence"],"0x0034":["SQ","1","VisualFieldCatchTrialSequence"],"0x0035":["US","1","FixationCheckedQuantity"],"0x0036":["US","1","PatientNotProperlyFixatedQuantity"],"0x0037":["CS","1","PresentedVisualStimuliDataFlag"],"0x0038":["US","1","NumberOfVisualStimuli"],"0x0039":["CS","1","ExcessiveFixationLossesDataFlag"],"0x0040":["CS","1","ExcessiveFixationLosses"],"0x0042":["US","1","StimuliRetestingQuantity"],"0x0044":["LT","1","CommentsOnPatientPerformanceOfVisualField"],"0x0045":["CS","1","FalseNegativesEstimateFlag"],"0x0046":["FL","1","FalseNegativesEstimate"],"0x0048":["US","1","NegativeCatchTrialsQuantity"],"0x0050":["US","1","FalseNegativesQuantity"],"0x0051":["CS","1","ExcessiveFalseNegativesDataFlag"],"0x0052":["CS","1","ExcessiveFalseNegatives"],"0x0053":["CS","1","FalsePositivesEstimateFlag"],"0x0054":["FL","1","FalsePositivesEstimate"],"0x0055":["CS","1","CatchTrialsDataFlag"],"0x0056":["US","1","PositiveCatchTrialsQuantity"],"0x0057":["CS","1","TestPointNormalsDataFlag"],"0x0058":["SQ","1","TestPointNormalsSequence"],"0x0059":["CS","1","GlobalDeviationProbabilityNormalsFlag"],"0x0060":["US","1","FalsePositivesQuantity"],"0x0061":["CS","1","ExcessiveFalsePositivesDataFlag"],"0x0062":["CS","1","ExcessiveFalsePositives"],"0x0063":["CS","1","VisualFieldTestNormalsFlag"],"0x0064":["SQ","1","ResultsNormalsSequence"],"0x0065":["SQ","1","AgeCorrectedSensitivityDeviationAlgorithmSequence"],"0x0066":["FL","1","GlobalDeviationFromNormal"],"0x0067":["SQ","1","GeneralizedDefectSensitivityDeviationAlgorithmSequence"],"0x0068":["FL","1","LocalizedDeviationFromNormal"],"0x0069":["LO","1","PatientReliabilityIndicator"],"0x0070":["FL","1","VisualFieldMeanSensitivity"],"0x0071":["FL","1","GlobalDeviationProbability"],"0x0072":["CS","1","LocalDeviationProbabilityNormalsFlag"],"0x0073":["FL","1","LocalizedDeviationProbability"],"0x0074":["CS","1","ShortTermFluctuationCalculated"],"0x0075":["FL","1","ShortTermFluctuation"],"0x0076":["CS","1","ShortTermFluctuationProbabilityCalculated"],"0x0077":["FL","1","ShortTermFluctuationProbability"],"0x0078":["CS","1","CorrectedLocalizedDeviationFromNormalCalculated"],"0x0079":["FL","1","CorrectedLocalizedDeviationFromNormal"],"0x0080":["CS","1","CorrectedLocalizedDeviationFromNormalProbabilityCalculated"],"0x0081":["FL","1","CorrectedLocalizedDeviationFromNormalProbability"],"0x0083":["SQ","1","GlobalDeviationProbabilitySequence"],"0x0085":["SQ","1","LocalizedDeviationProbabilitySequence"],"0x0086":["CS","1","FovealSensitivityMeasured"],"0x0087":["FL","1","FovealSensitivity"],"0x0088":["FL","1","VisualFieldTestDuration"],"0x0089":["SQ","1","VisualFieldTestPointSequence"],"0x0090":["FL","1","VisualFieldTestPointXCoordinate"],"0x0091":["FL","1","VisualFieldTestPointYCoordinate"],"0x0092":["FL","1","AgeCorrectedSensitivityDeviationValue"],"0x0093":["CS","1","StimulusResults"],"0x0094":["FL","1","SensitivityValue"],"0x0095":["CS","1","RetestStimulusSeen"],"0x0096":["FL","1","RetestSensitivityValue"],"0x0097":["SQ","1","VisualFieldTestPointNormalsSequence"],"0x0098":["FL","1","QuantifiedDefect"],"0x0100":["FL","1","AgeCorrectedSensitivityDeviationProbabilityValue"],"0x0102":["CS","1","GeneralizedDefectCorrectedSensitivityDeviationFlag"],"0x0103":["FL","1","GeneralizedDefectCorrectedSensitivityDeviationValue"],"0x0104":["FL","1","GeneralizedDefectCorrectedSensitivityDeviationProbabilityValue"],"0x0105":["FL","1","MinimumSensitivityValue"],"0x0106":["CS","1","BlindSpotLocalized"],"0x0107":["FL","1","BlindSpotXCoordinate"],"0x0108":["FL","1","BlindSpotYCoordinate"],"0x0110":["SQ","1","VisualAcuityMeasurementSequence"],"0x0112":["SQ","1","RefractiveParametersUsedOnPatientSequence"],"0x0113":["CS","1","MeasurementLaterality"],"0x0114":["SQ","1","OphthalmicPatientClinicalInformationLeftEyeSequence"],"0x0115":["SQ","1","OphthalmicPatientClinicalInformationRightEyeSequence"],"0x0117":["CS","1","FovealPointNormativeDataFlag"],"0x0118":["FL","1","FovealPointProbabilityValue"],"0x0120":["CS","1","ScreeningBaselineMeasured"],"0x0122":["SQ","1","ScreeningBaselineMeasuredSequence"],"0x0124":["CS","1","ScreeningBaselineType"],"0x0126":["FL","1","ScreeningBaselineValue"],"0x0202":["LO","1","AlgorithmSource"],"0x0306":["LO","1","DataSetName"],"0x0307":["LO","1","DataSetVersion"],"0x0308":["LO","1","DataSetSource"],"0x0309":["LO","1","DataSetDescription"],"0x0317":["SQ","1","VisualFieldTestReliabilityGlobalIndexSequence"],"0x0320":["SQ","1","VisualFieldGlobalResultsIndexSequence"],"0x0325":["SQ","1","DataObservationSequence"],"0x0338":["CS","1","IndexNormalsFlag"],"0x0341":["FL","1","IndexProbability"],"0x0344":["SQ","1","IndexProbabilitySequence"]},"0x0028":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["US","1","SamplesPerPixel"],"0x0003":["US","1","SamplesPerPixelUsed"],"0x0004":["CS","1","PhotometricInterpretation"],"0x0005":["US","1","ImageDimensions"],"0x0006":["US","1","PlanarConfiguration"],"0x0008":["IS","1","NumberOfFrames"],"0x0009":["AT","1-n","FrameIncrementPointer"],"0x000A":["AT","1-n","FrameDimensionPointer"],"0x0010":["US","1","Rows"],"0x0011":["US","1","Columns"],"0x0012":["US","1","Planes"],"0x0014":["US","1","UltrasoundColorDataPresent"],"0x0020":["","",""],"0x0030":["DS","2","PixelSpacing"],"0x0031":["DS","2","ZoomFactor"],"0x0032":["DS","2","ZoomCenter"],"0x0034":["IS","2","PixelAspectRatio"],"0x0040":["CS","1","ImageFormat"],"0x0050":["LO","1-n","ManipulatedImage"],"0x0051":["CS","1-n","CorrectedImage"],"0x005F":["LO","1","CompressionRecognitionCode"],"0x0060":["CS","1","CompressionCode"],"0x0061":["SH","1","CompressionOriginator"],"0x0062":["LO","1","CompressionLabel"],"0x0063":["SH","1","CompressionDescription"],"0x0065":["CS","1-n","CompressionSequence"],"0x0066":["AT","1-n","CompressionStepPointers"],"0x0068":["US","1","RepeatInterval"],"0x0069":["US","1","BitsGrouped"],"0x0070":["US","1-n","PerimeterTable"],"0x0071":["xs","1","PerimeterValue"],"0x0080":["US","1","PredictorRows"],"0x0081":["US","1","PredictorColumns"],"0x0082":["US","1-n","PredictorConstants"],"0x0090":["CS","1","BlockedPixels"],"0x0091":["US","1","BlockRows"],"0x0092":["US","1","BlockColumns"],"0x0093":["US","1","RowOverlap"],"0x0094":["US","1","ColumnOverlap"],"0x0100":["US","1","BitsAllocated"],"0x0101":["US","1","BitsStored"],"0x0102":["US","1","HighBit"],"0x0103":["US","1","PixelRepresentation"],"0x0104":["xs","1","SmallestValidPixelValue"],"0x0105":["xs","1","LargestValidPixelValue"],"0x0106":["xs","1","SmallestImagePixelValue"],"0x0107":["xs","1","LargestImagePixelValue"],"0x0108":["xs","1","SmallestPixelValueInSeries"],"0x0109":["xs","1","LargestPixelValueInSeries"],"0x0110":["xs","1","SmallestImagePixelValueInPlane"],"0x0111":["xs","1","LargestImagePixelValueInPlane"],"0x0120":["xs","1","PixelPaddingValue"],"0x0121":["xs","1","PixelPaddingRangeLimit"],"0x0122":["FL","1","FloatPixelPaddingValue"],"0x0123":["FD","1","DoubleFloatPixelPaddingValue"],"0x0124":["FL","1","FloatPixelPaddingRangeLimit"],"0x0125":["FD","1","DoubleFloatPixelPaddingRangeLimit"],"0x0200":["US","1","ImageLocation"],"0x0300":["CS","1","QualityControlImage"],"0x0301":["CS","1","BurnedInAnnotation"],"0x0302":["CS","1","RecognizableVisualFeatures"],"0x0303":["CS","1","LongitudinalTemporalInformationModified"],"0x0304":["UI","1","ReferencedColorPaletteInstanceUID"],"0x0400":["LO","1","TransformLabel"],"0x0401":["LO","1","TransformVersionNumber"],"0x0402":["US","1","NumberOfTransformSteps"],"0x0403":["LO","1-n","SequenceOfCompressedData"],"0x0404":["AT","1-n","DetailsOfCoefficients"],"0x04x0":["US","1","RowsForNthOrderCoefficients"],"0x04x1":["US","1","ColumnsForNthOrderCoefficients"],"0x04x2":["LO","1-n","CoefficientCoding"],"0x04x3":["AT","1-n","CoefficientCodingPointers"],"0x0700":["LO","1","DCTLabel"],"0x0701":["CS","1-n","DataBlockDescription"],"0x0702":["AT","1-n","DataBlock"],"0x0710":["US","1","NormalizationFactorFormat"],"0x0720":["US","1","ZonalMapNumberFormat"],"0x0721":["AT","1-n","ZonalMapLocation"],"0x0722":["US","1","ZonalMapFormat"],"0x0730":["US","1","AdaptiveMapFormat"],"0x0740":["US","1","CodeNumberFormat"],"0x08x0":["CS","1-n","CodeLabel"],"0x08x2":["US","1","NumberOfTables"],"0x08x3":["AT","1-n","CodeTableLocation"],"0x08x4":["US","1","BitsForCodeWord"],"0x08x8":["AT","1-n","ImageDataLocation"],"0x0A02":["CS","1","PixelSpacingCalibrationType"],"0x0A04":["LO","1","PixelSpacingCalibrationDescription"],"0x1040":["CS","1","PixelIntensityRelationship"],"0x1041":["SS","1","PixelIntensityRelationshipSign"],"0x1050":["DS","1-n","WindowCenter"],"0x1051":["DS","1-n","WindowWidth"],"0x1052":["DS","1","RescaleIntercept"],"0x1053":["DS","1","RescaleSlope"],"0x1054":["LO","1","RescaleType"],"0x1055":["LO","1-n","WindowCenterWidthExplanation"],"0x1056":["CS","1","VOILUTFunction"],"0x1080":["CS","1","GrayScale"],"0x1090":["CS","1","RecommendedViewingMode"],"0x1100":["xs","3","GrayLookupTableDescriptor"],"0x1101":["xs","3","RedPaletteColorLookupTableDescriptor"],"0x1102":["xs","3","GreenPaletteColorLookupTableDescriptor"],"0x1103":["xs","3","BluePaletteColorLookupTableDescriptor"],"0x1104":["US","3","AlphaPaletteColorLookupTableDescriptor"],"0x1111":["xs","4","LargeRedPaletteColorLookupTableDescriptor"],"0x1112":["xs","4","LargeGreenPaletteColorLookupTableDescriptor"],"0x1113":["xs","4","LargeBluePaletteColorLookupTableDescriptor"],"0x1199":["UI","1","PaletteColorLookupTableUID"],"0x1200":["US or SS or OW","1-n or 1","GrayLookupTableData"],"0x1201":["OW","1","RedPaletteColorLookupTableData"],"0x1202":["OW","1","GreenPaletteColorLookupTableData"],"0x1203":["OW","1","BluePaletteColorLookupTableData"],"0x1204":["OW","1","AlphaPaletteColorLookupTableData"],"0x1211":["OW","1","LargeRedPaletteColorLookupTableData"],"0x1212":["OW","1","LargeGreenPaletteColorLookupTableData"],"0x1213":["OW","1","LargeBluePaletteColorLookupTableData"],"0x1214":["UI","1","LargePaletteColorLookupTableUID"],"0x1221":["OW","1","SegmentedRedPaletteColorLookupTableData"],"0x1222":["OW","1","SegmentedGreenPaletteColorLookupTableData"],"0x1223":["OW","1","SegmentedBluePaletteColorLookupTableData"],"0x1224":["OW","1","SegmentedAlphaPaletteColorLookupTableData"],"0x1230":["SQ","1","StoredValueColorRangeSequence"],"0x1231":["FD","1","MinimumStoredValueMapped"],"0x1232":["FD","1","MaximumStoredValueMapped"],"0x1300":["CS","1","BreastImplantPresent"],"0x1350":["CS","1","PartialView"],"0x1351":["ST","1","PartialViewDescription"],"0x1352":["SQ","1","PartialViewCodeSequence"],"0x135A":["CS","1","SpatialLocationsPreserved"],"0x1401":["SQ","1","DataFrameAssignmentSequence"],"0x1402":["CS","1","DataPathAssignment"],"0x1403":["US","1","BitsMappedToColorLookupTable"],"0x1404":["SQ","1","BlendingLUT1Sequence"],"0x1405":["CS","1","BlendingLUT1TransferFunction"],"0x1406":["FD","1","BlendingWeightConstant"],"0x1407":["US","3","BlendingLookupTableDescriptor"],"0x1408":["OW","1","BlendingLookupTableData"],"0x140B":["SQ","1","EnhancedPaletteColorLookupTableSequence"],"0x140C":["SQ","1","BlendingLUT2Sequence"],"0x140D":["CS","1","BlendingLUT2TransferFunction"],"0x140E":["CS","1","DataPathID"],"0x140F":["CS","1","RGBLUTTransferFunction"],"0x1410":["CS","1","AlphaLUTTransferFunction"],"0x2000":["OB","1","ICCProfile"],"0x2002":["CS","1","ColorSpace"],"0x2110":["CS","1","LossyImageCompression"],"0x2112":["DS","1-n","LossyImageCompressionRatio"],"0x2114":["CS","1-n","LossyImageCompressionMethod"],"0x3000":["SQ","1","ModalityLUTSequence"],"0x3002":["xs","3","LUTDescriptor"],"0x3003":["LO","1","LUTExplanation"],"0x3004":["LO","1","ModalityLUTType"],"0x3006":["US or OW","1-n or 1","LUTData"],"0x3010":["SQ","1","VOILUTSequence"],"0x3110":["SQ","1","SoftcopyVOILUTSequence"],"0x4000":["LT","1","ImagePresentationComments"],"0x5000":["SQ","1","BiPlaneAcquisitionSequence"],"0x6010":["US","1","RepresentativeFrameNumber"],"0x6020":["US","1-n","FrameNumbersOfInterest"],"0x6022":["LO","1-n","FrameOfInterestDescription"],"0x6023":["CS","1-n","FrameOfInterestType"],"0x6030":["US","1-n","MaskPointers"],"0x6040":["US","1-n","RWavePointer"],"0x6100":["SQ","1","MaskSubtractionSequence"],"0x6101":["CS","1","MaskOperation"],"0x6102":["US","2-2n","ApplicableFrameRange"],"0x6110":["US","1-n","MaskFrameNumbers"],"0x6112":["US","1","ContrastFrameAveraging"],"0x6114":["FL","2","MaskSubPixelShift"],"0x6120":["SS","1","TIDOffset"],"0x6190":["ST","1","MaskOperationExplanation"],"0x7000":["SQ","1","EquipmentAdministratorSequence"],"0x7001":["US","1","NumberOfDisplaySubsystems"],"0x7002":["US","1","CurrentConfigurationID"],"0x7003":["US","1","DisplaySubsystemID"],"0x7004":["SH","1","DisplaySubsystemName"],"0x7005":["LO","1","DisplaySubsystemDescription"],"0x7006":["CS","1","SystemStatus"],"0x7007":["LO","1","SystemStatusComment"],"0x7008":["SQ","1","TargetLuminanceCharacteristicsSequence"],"0x7009":["US","1","LuminanceCharacteristicsID"],"0x700A":["SQ","1","DisplaySubsystemConfigurationSequence"],"0x700B":["US","1","ConfigurationID"],"0x700C":["SH","1","ConfigurationName"],"0x700D":["LO","1","ConfigurationDescription"],"0x700E":["US","1","ReferencedTargetLuminanceCharacteristicsID"],"0x700F":["SQ","1","QAResultsSequence"],"0x7010":["SQ","1","DisplaySubsystemQAResultsSequence"],"0x7011":["SQ","1","ConfigurationQAResultsSequence"],"0x7012":["SQ","1","MeasurementEquipmentSequence"],"0x7013":["CS","1-n","MeasurementFunctions"],"0x7014":["CS","1","MeasurementEquipmentType"],"0x7015":["SQ","1","VisualEvaluationResultSequence"],"0x7016":["SQ","1","DisplayCalibrationResultSequence"],"0x7017":["US","1","DDLValue"],"0x7018":["FL","2","CIExyWhitePoint"],"0x7019":["CS","1","DisplayFunctionType"],"0x701A":["FL","1","GammaValue"],"0x701B":["US","1","NumberOfLuminancePoints"],"0x701C":["SQ","1","LuminanceResponseSequence"],"0x701D":["FL","1","TargetMinimumLuminance"],"0x701E":["FL","1","TargetMaximumLuminance"],"0x701F":["FL","1","LuminanceValue"],"0x7020":["LO","1","LuminanceResponseDescription"],"0x7021":["CS","1","WhitePointFlag"],"0x7022":["SQ","1","DisplayDeviceTypeCodeSequence"],"0x7023":["SQ","1","DisplaySubsystemSequence"],"0x7024":["SQ","1","LuminanceResultSequence"],"0x7025":["CS","1","AmbientLightValueSource"],"0x7026":["CS","1-n","MeasuredCharacteristics"],"0x7027":["SQ","1","LuminanceUniformityResultSequence"],"0x7028":["SQ","1","VisualEvaluationTestSequence"],"0x7029":["CS","1","TestResult"],"0x702A":["LO","1","TestResultComment"],"0x702B":["CS","1","TestImageValidation"],"0x702C":["SQ","1","TestPatternCodeSequence"],"0x702D":["SQ","1","MeasurementPatternCodeSequence"],"0x702E":["SQ","1","VisualEvaluationMethodCodeSequence"],"0x7FE0":["UR","1","PixelDataProviderURL"],"0x9001":["UL","1","DataPointRows"],"0x9002":["UL","1","DataPointColumns"],"0x9003":["CS","1","SignalDomainColumns"],"0x9099":["US","1","LargestMonochromePixelValue"],"0x9108":["CS","1","DataRepresentation"],"0x9110":["SQ","1","PixelMeasuresSequence"],"0x9132":["SQ","1","FrameVOILUTSequence"],"0x9145":["SQ","1","PixelValueTransformationSequence"],"0x9235":["CS","1","SignalDomainRows"],"0x9411":["FL","1","DisplayFilterPercentage"],"0x9415":["SQ","1","FramePixelShiftSequence"],"0x9416":["US","1","SubtractionItemID"],"0x9422":["SQ","1","PixelIntensityRelationshipLUTSequence"],"0x9443":["SQ","1","FramePixelDataPropertiesSequence"],"0x9444":["CS","1","GeometricalProperties"],"0x9445":["FL","1","GeometricMaximumDistortion"],"0x9446":["CS","1-n","ImageProcessingApplied"],"0x9454":["CS","1","MaskSelectionMode"],"0x9474":["CS","1","LUTFunction"],"0x9478":["FL","1","MaskVisibilityPercentage"],"0x9501":["SQ","1","PixelShiftSequence"],"0x9502":["SQ","1","RegionPixelShiftSequence"],"0x9503":["SS","2-2n","VerticesOfTheRegion"],"0x9505":["SQ","1","MultiFramePresentationSequence"],"0x9506":["US","2-2n","PixelShiftFrameRange"],"0x9507":["US","2-2n","LUTFrameRange"],"0x9520":["DS","16","ImageToEquipmentMappingMatrix"],"0x9537":["CS","1","EquipmentCoordinateSystemIdentification"]},"0x0032":{"0x0000":["UL","1","GenericGroupLength"],"0x000A":["CS","1","StudyStatusID"],"0x000C":["CS","1","StudyPriorityID"],"0x0012":["LO","1","StudyIDIssuer"],"0x0032":["DA","1","StudyVerifiedDate"],"0x0033":["TM","1","StudyVerifiedTime"],"0x0034":["DA","1","StudyReadDate"],"0x0035":["TM","1","StudyReadTime"],"0x1000":["DA","1","ScheduledStudyStartDate"],"0x1001":["TM","1","ScheduledStudyStartTime"],"0x1010":["DA","1","ScheduledStudyStopDate"],"0x1011":["TM","1","ScheduledStudyStopTime"],"0x1020":["LO","1","ScheduledStudyLocation"],"0x1021":["AE","1-n","ScheduledStudyLocationAETitle"],"0x1030":["LO","1","ReasonForStudy"],"0x1031":["SQ","1","RequestingPhysicianIdentificationSequence"],"0x1032":["PN","1","RequestingPhysician"],"0x1033":["LO","1","RequestingService"],"0x1034":["SQ","1","RequestingServiceCodeSequence"],"0x1040":["DA","1","StudyArrivalDate"],"0x1041":["TM","1","StudyArrivalTime"],"0x1050":["DA","1","StudyCompletionDate"],"0x1051":["TM","1","StudyCompletionTime"],"0x1055":["CS","1","StudyComponentStatusID"],"0x1060":["LO","1","RequestedProcedureDescription"],"0x1064":["SQ","1","RequestedProcedureCodeSequence"],"0x1065":["SQ","1","RequestedLateralityCodeSequence"],"0x1066":["UT","1","ReasonForVisit"],"0x1067":["SQ","1","ReasonForVisitCodeSequence"],"0x1070":["LO","1","RequestedContrastAgent"],"0x4000":["LT","1","StudyComments"]},"0x0034":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["SQ","1","FlowIdentifierSequence"],"0x0002":["OB","1","FlowIdentifier"],"0x0003":["UI","1","FlowTransferSyntaxUID"],"0x0004":["UL","1","FlowRTPSamplingRate"],"0x0005":["OB","1","SourceIdentifier"],"0x0007":["OB","1","FrameOriginTimestamp"],"0x0008":["CS","1","IncludesImagingSubject"],"0x0009":["SQ","1","FrameUsefulnessGroupSequence"],"0x000A":["SQ","1","RealTimeBulkDataFlowSequence"],"0x000B":["SQ","1","CameraPositionGroupSequence"],"0x000C":["CS","1","IncludesInformation"],"0x000D":["SQ","1","TimeOfFrameGroupSequence"]},"0x0038":{"0x0000":["UL","1","GenericGroupLength"],"0x0004":["SQ","1","ReferencedPatientAliasSequence"],"0x0008":["CS","1","VisitStatusID"],"0x0010":["LO","1","AdmissionID"],"0x0011":["LO","1","IssuerOfAdmissionID"],"0x0014":["SQ","1","IssuerOfAdmissionIDSequence"],"0x0016":["LO","1","RouteOfAdmissions"],"0x001A":["DA","1","ScheduledAdmissionDate"],"0x001B":["TM","1","ScheduledAdmissionTime"],"0x001C":["DA","1","ScheduledDischargeDate"],"0x001D":["TM","1","ScheduledDischargeTime"],"0x001E":["LO","1","ScheduledPatientInstitutionResidence"],"0x0020":["DA","1","AdmittingDate"],"0x0021":["TM","1","AdmittingTime"],"0x0030":["DA","1","DischargeDate"],"0x0032":["TM","1","DischargeTime"],"0x0040":["LO","1","DischargeDiagnosisDescription"],"0x0044":["SQ","1","DischargeDiagnosisCodeSequence"],"0x0050":["LO","1","SpecialNeeds"],"0x0060":["LO","1","ServiceEpisodeID"],"0x0061":["LO","1","IssuerOfServiceEpisodeID"],"0x0062":["LO","1","ServiceEpisodeDescription"],"0x0064":["SQ","1","IssuerOfServiceEpisodeIDSequence"],"0x0100":["SQ","1","PertinentDocumentsSequence"],"0x0101":["SQ","1","PertinentResourcesSequence"],"0x0102":["LO","1","ResourceDescription"],"0x0300":["LO","1","CurrentPatientLocation"],"0x0400":["LO","1","PatientInstitutionResidence"],"0x0500":["LO","1","PatientState"],"0x0502":["SQ","1","PatientClinicalTrialParticipationSequence"],"0x4000":["LT","1","VisitComments"]},"0x003A":{"0x0000":["UL","1","GenericGroupLength"],"0x0004":["CS","1","WaveformOriginality"],"0x0005":["US","1","NumberOfWaveformChannels"],"0x0010":["UL","1","NumberOfWaveformSamples"],"0x001A":["DS","1","SamplingFrequency"],"0x0020":["SH","1","MultiplexGroupLabel"],"0x0200":["SQ","1","ChannelDefinitionSequence"],"0x0202":["IS","1","WaveformChannelNumber"],"0x0203":["SH","1","ChannelLabel"],"0x0205":["CS","1-n","ChannelStatus"],"0x0208":["SQ","1","ChannelSourceSequence"],"0x0209":["SQ","1","ChannelSourceModifiersSequence"],"0x020A":["SQ","1","SourceWaveformSequence"],"0x020C":["LO","1","ChannelDerivationDescription"],"0x0210":["DS","1","ChannelSensitivity"],"0x0211":["SQ","1","ChannelSensitivityUnitsSequence"],"0x0212":["DS","1","ChannelSensitivityCorrectionFactor"],"0x0213":["DS","1","ChannelBaseline"],"0x0214":["DS","1","ChannelTimeSkew"],"0x0215":["DS","1","ChannelSampleSkew"],"0x0218":["DS","1","ChannelOffset"],"0x021A":["US","1","WaveformBitsStored"],"0x0220":["DS","1","FilterLowFrequency"],"0x0221":["DS","1","FilterHighFrequency"],"0x0222":["DS","1","NotchFilterFrequency"],"0x0223":["DS","1","NotchFilterBandwidth"],"0x0230":["FL","1","WaveformDataDisplayScale"],"0x0231":["US","3","WaveformDisplayBackgroundCIELabValue"],"0x0240":["SQ","1","WaveformPresentationGroupSequence"],"0x0241":["US","1","PresentationGroupNumber"],"0x0242":["SQ","1","ChannelDisplaySequence"],"0x0244":["US","3","ChannelRecommendedDisplayCIELabValue"],"0x0245":["FL","1","ChannelPosition"],"0x0246":["CS","1","DisplayShadingFlag"],"0x0247":["FL","1","FractionalChannelDisplayScale"],"0x0248":["FL","1","AbsoluteChannelDisplayScale"],"0x0300":["SQ","1","MultiplexedAudioChannelsDescriptionCodeSequence"],"0x0301":["IS","1","ChannelIdentificationCode"],"0x0302":["CS","1","ChannelMode"],"0x0310":["UI","1","MultiplexGroupUID"],"0x0311":["DS","1","PowerlineFrequency"],"0x0312":["SQ","1","ChannelImpedanceSequence"],"0x0313":["DS","1","ImpedanceValue"],"0x0314":["DT","1","ImpedanceMeasurementDateTime"],"0x0315":["DS","1","ImpedanceMeasurementFrequency"],"0x0316":["CS","1","ImpedanceMeasurementCurrentType"]},"0x0040":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["AE","1-n","ScheduledStationAETitle"],"0x0002":["DA","1","ScheduledProcedureStepStartDate"],"0x0003":["TM","1","ScheduledProcedureStepStartTime"],"0x0004":["DA","1","ScheduledProcedureStepEndDate"],"0x0005":["TM","1","ScheduledProcedureStepEndTime"],"0x0006":["PN","1","ScheduledPerformingPhysicianName"],"0x0007":["LO","1","ScheduledProcedureStepDescription"],"0x0008":["SQ","1","ScheduledProtocolCodeSequence"],"0x0009":["SH","1","ScheduledProcedureStepID"],"0x000A":["SQ","1","StageCodeSequence"],"0x000B":["SQ","1","ScheduledPerformingPhysicianIdentificationSequence"],"0x0010":["SH","1-n","ScheduledStationName"],"0x0011":["SH","1","ScheduledProcedureStepLocation"],"0x0012":["LO","1","PreMedication"],"0x0020":["CS","1","ScheduledProcedureStepStatus"],"0x0026":["SQ","1","OrderPlacerIdentifierSequence"],"0x0027":["SQ","1","OrderFillerIdentifierSequence"],"0x0031":["UT","1","LocalNamespaceEntityID"],"0x0032":["UT","1","UniversalEntityID"],"0x0033":["CS","1","UniversalEntityIDType"],"0x0035":["CS","1","IdentifierTypeCode"],"0x0036":["SQ","1","AssigningFacilitySequence"],"0x0039":["SQ","1","AssigningJurisdictionCodeSequence"],"0x003A":["SQ","1","AssigningAgencyOrDepartmentCodeSequence"],"0x0100":["SQ","1","ScheduledProcedureStepSequence"],"0x0220":["SQ","1","ReferencedNonImageCompositeSOPInstanceSequence"],"0x0241":["AE","1","PerformedStationAETitle"],"0x0242":["SH","1","PerformedStationName"],"0x0243":["SH","1","PerformedLocation"],"0x0244":["DA","1","PerformedProcedureStepStartDate"],"0x0245":["TM","1","PerformedProcedureStepStartTime"],"0x0250":["DA","1","PerformedProcedureStepEndDate"],"0x0251":["TM","1","PerformedProcedureStepEndTime"],"0x0252":["CS","1","PerformedProcedureStepStatus"],"0x0253":["SH","1","PerformedProcedureStepID"],"0x0254":["LO","1","PerformedProcedureStepDescription"],"0x0255":["LO","1","PerformedProcedureTypeDescription"],"0x0260":["SQ","1","PerformedProtocolCodeSequence"],"0x0261":["CS","1","PerformedProtocolType"],"0x0270":["SQ","1","ScheduledStepAttributesSequence"],"0x0275":["SQ","1","RequestAttributesSequence"],"0x0280":["ST","1","CommentsOnThePerformedProcedureStep"],"0x0281":["SQ","1","PerformedProcedureStepDiscontinuationReasonCodeSequence"],"0x0293":["SQ","1","QuantitySequence"],"0x0294":["DS","1","Quantity"],"0x0295":["SQ","1","MeasuringUnitsSequence"],"0x0296":["SQ","1","BillingItemSequence"],"0x0300":["US","1","TotalTimeOfFluoroscopy"],"0x0301":["US","1","TotalNumberOfExposures"],"0x0302":["US","1","EntranceDose"],"0x0303":["US","1-2","ExposedArea"],"0x0306":["DS","1","DistanceSourceToEntrance"],"0x0307":["DS","1","DistanceSourceToSupport"],"0x030E":["SQ","1","ExposureDoseSequence"],"0x0310":["ST","1","CommentsOnRadiationDose"],"0x0312":["DS","1","XRayOutput"],"0x0314":["DS","1","HalfValueLayer"],"0x0316":["DS","1","OrganDose"],"0x0318":["CS","1","OrganExposed"],"0x0320":["SQ","1","BillingProcedureStepSequence"],"0x0321":["SQ","1","FilmConsumptionSequence"],"0x0324":["SQ","1","BillingSuppliesAndDevicesSequence"],"0x0330":["SQ","1","ReferencedProcedureStepSequence"],"0x0340":["SQ","1","PerformedSeriesSequence"],"0x0400":["LT","1","CommentsOnTheScheduledProcedureStep"],"0x0440":["SQ","1","ProtocolContextSequence"],"0x0441":["SQ","1","ContentItemModifierSequence"],"0x0500":["SQ","1","ScheduledSpecimenSequence"],"0x050A":["LO","1","SpecimenAccessionNumber"],"0x0512":["LO","1","ContainerIdentifier"],"0x0513":["SQ","1","IssuerOfTheContainerIdentifierSequence"],"0x0515":["SQ","1","AlternateContainerIdentifierSequence"],"0x0518":["SQ","1","ContainerTypeCodeSequence"],"0x051A":["LO","1","ContainerDescription"],"0x0520":["SQ","1","ContainerComponentSequence"],"0x0550":["SQ","1","SpecimenSequence"],"0x0551":["LO","1","SpecimenIdentifier"],"0x0552":["SQ","1","SpecimenDescriptionSequenceTrial"],"0x0553":["ST","1","SpecimenDescriptionTrial"],"0x0554":["UI","1","SpecimenUID"],"0x0555":["SQ","1","AcquisitionContextSequence"],"0x0556":["ST","1","AcquisitionContextDescription"],"0x0560":["SQ","1","SpecimenDescriptionSequence"],"0x0562":["SQ","1","IssuerOfTheSpecimenIdentifierSequence"],"0x059A":["SQ","1","SpecimenTypeCodeSequence"],"0x0600":["LO","1","SpecimenShortDescription"],"0x0602":["UT","1","SpecimenDetailedDescription"],"0x0610":["SQ","1","SpecimenPreparationSequence"],"0x0612":["SQ","1","SpecimenPreparationStepContentItemSequence"],"0x0620":["SQ","1","SpecimenLocalizationContentItemSequence"],"0x06FA":["LO","1","SlideIdentifier"],"0x0710":["SQ","1","WholeSlideMicroscopyImageFrameTypeSequence"],"0x071A":["SQ","1","ImageCenterPointCoordinatesSequence"],"0x072A":["DS","1","XOffsetInSlideCoordinateSystem"],"0x073A":["DS","1","YOffsetInSlideCoordinateSystem"],"0x074A":["DS","1","ZOffsetInSlideCoordinateSystem"],"0x08D8":["SQ","1","PixelSpacingSequence"],"0x08DA":["SQ","1","CoordinateSystemAxisCodeSequence"],"0x08EA":["SQ","1","MeasurementUnitsCodeSequence"],"0x09F8":["SQ","1","VitalStainCodeSequenceTrial"],"0x1001":["SH","1","RequestedProcedureID"],"0x1002":["LO","1","ReasonForTheRequestedProcedure"],"0x1003":["SH","1","RequestedProcedurePriority"],"0x1004":["LO","1","PatientTransportArrangements"],"0x1005":["LO","1","RequestedProcedureLocation"],"0x1006":["SH","1","PlacerOrderNumberProcedure"],"0x1007":["SH","1","FillerOrderNumberProcedure"],"0x1008":["LO","1","ConfidentialityCode"],"0x1009":["SH","1","ReportingPriority"],"0x100A":["SQ","1","ReasonForRequestedProcedureCodeSequence"],"0x1010":["PN","1-n","NamesOfIntendedRecipientsOfResults"],"0x1011":["SQ","1","IntendedRecipientsOfResultsIdentificationSequence"],"0x1012":["SQ","1","ReasonForPerformedProcedureCodeSequence"],"0x1060":["LO","1","RequestedProcedureDescriptionTrial"],"0x1101":["SQ","1","PersonIdentificationCodeSequence"],"0x1102":["ST","1","PersonAddress"],"0x1103":["LO","1-n","PersonTelephoneNumbers"],"0x1104":["LT","1","PersonTelecomInformation"],"0x1400":["LT","1","RequestedProcedureComments"],"0x2001":["LO","1","ReasonForTheImagingServiceRequest"],"0x2004":["DA","1","IssueDateOfImagingServiceRequest"],"0x2005":["TM","1","IssueTimeOfImagingServiceRequest"],"0x2006":["SH","1","PlacerOrderNumberImagingServiceRequestRetired"],"0x2007":["SH","1","FillerOrderNumberImagingServiceRequestRetired"],"0x2008":["PN","1","OrderEnteredBy"],"0x2009":["SH","1","OrderEntererLocation"],"0x2010":["SH","1","OrderCallbackPhoneNumber"],"0x2011":["LT","1","OrderCallbackTelecomInformation"],"0x2016":["LO","1","PlacerOrderNumberImagingServiceRequest"],"0x2017":["LO","1","FillerOrderNumberImagingServiceRequest"],"0x2400":["LT","1","ImagingServiceRequestComments"],"0x3001":["LO","1","ConfidentialityConstraintOnPatientDataDescription"],"0x4001":["CS","1","GeneralPurposeScheduledProcedureStepStatus"],"0x4002":["CS","1","GeneralPurposePerformedProcedureStepStatus"],"0x4003":["CS","1","GeneralPurposeScheduledProcedureStepPriority"],"0x4004":["SQ","1","ScheduledProcessingApplicationsCodeSequence"],"0x4005":["DT","1","ScheduledProcedureStepStartDateTime"],"0x4006":["CS","1","MultipleCopiesFlag"],"0x4007":["SQ","1","PerformedProcessingApplicationsCodeSequence"],"0x4008":["DT","1","ScheduledProcedureStepExpirationDateTime"],"0x4009":["SQ","1","HumanPerformerCodeSequence"],"0x4010":["DT","1","ScheduledProcedureStepModificationDateTime"],"0x4011":["DT","1","ExpectedCompletionDateTime"],"0x4015":["SQ","1","ResultingGeneralPurposePerformedProcedureStepsSequence"],"0x4016":["SQ","1","ReferencedGeneralPurposeScheduledProcedureStepSequence"],"0x4018":["SQ","1","ScheduledWorkitemCodeSequence"],"0x4019":["SQ","1","PerformedWorkitemCodeSequence"],"0x4020":["CS","1","InputAvailabilityFlag"],"0x4021":["SQ","1","InputInformationSequence"],"0x4022":["SQ","1","RelevantInformationSequence"],"0x4023":["UI","1","ReferencedGeneralPurposeScheduledProcedureStepTransactionUID"],"0x4025":["SQ","1","ScheduledStationNameCodeSequence"],"0x4026":["SQ","1","ScheduledStationClassCodeSequence"],"0x4027":["SQ","1","ScheduledStationGeographicLocationCodeSequence"],"0x4028":["SQ","1","PerformedStationNameCodeSequence"],"0x4029":["SQ","1","PerformedStationClassCodeSequence"],"0x4030":["SQ","1","PerformedStationGeographicLocationCodeSequence"],"0x4031":["SQ","1","RequestedSubsequentWorkitemCodeSequence"],"0x4032":["SQ","1","NonDICOMOutputCodeSequence"],"0x4033":["SQ","1","OutputInformationSequence"],"0x4034":["SQ","1","ScheduledHumanPerformersSequence"],"0x4035":["SQ","1","ActualHumanPerformersSequence"],"0x4036":["LO","1","HumanPerformerOrganization"],"0x4037":["PN","1","HumanPerformerName"],"0x4040":["CS","1","RawDataHandling"],"0x4041":["CS","1","InputReadinessState"],"0x4050":["DT","1","PerformedProcedureStepStartDateTime"],"0x4051":["DT","1","PerformedProcedureStepEndDateTime"],"0x4052":["DT","1","ProcedureStepCancellationDateTime"],"0x4070":["SQ","1","OutputDestinationSequence"],"0x4071":["SQ","1","DICOMStorageSequence"],"0x4072":["SQ","1","STOWRSStorageSequence"],"0x4073":["UR","1","StorageURL"],"0x4074":["SQ","1","XDSStorageSequence"],"0x8302":["DS","1","EntranceDoseInmGy"],"0x8303":["CS","1","EntranceDoseDerivation"],"0x9092":["SQ","1","ParametricMapFrameTypeSequence"],"0x9094":["SQ","1","ReferencedImageRealWorldValueMappingSequence"],"0x9096":["SQ","1","RealWorldValueMappingSequence"],"0x9098":["SQ","1","PixelValueMappingCodeSequence"],"0x9210":["SH","1","LUTLabel"],"0x9211":["xs","1","RealWorldValueLastValueMapped"],"0x9212":["FD","1-n","RealWorldValueLUTData"],"0x9213":["FD","1","DoubleFloatRealWorldValueLastValueMapped"],"0x9214":["FD","1","DoubleFloatRealWorldValueFirstValueMapped"],"0x9216":["xs","1","RealWorldValueFirstValueMapped"],"0x9220":["SQ","1","QuantityDefinitionSequence"],"0x9224":["FD","1","RealWorldValueIntercept"],"0x9225":["FD","1","RealWorldValueSlope"],"0xA007":["CS","1","FindingsFlagTrial"],"0xA010":["CS","1","RelationshipType"],"0xA020":["SQ","1","FindingsSequenceTrial"],"0xA021":["UI","1","FindingsGroupUIDTrial"],"0xA022":["UI","1","ReferencedFindingsGroupUIDTrial"],"0xA023":["DA","1","FindingsGroupRecordingDateTrial"],"0xA024":["TM","1","FindingsGroupRecordingTimeTrial"],"0xA026":["SQ","1","FindingsSourceCategoryCodeSequenceTrial"],"0xA027":["LO","1","VerifyingOrganization"],"0xA028":["SQ","1","DocumentingOrganizationIdentifierCodeSequenceTrial"],"0xA030":["DT","1","VerificationDateTime"],"0xA032":["DT","1","ObservationDateTime"],"0xA033":["DT","1","ObservationStartDateTime"],"0xA040":["CS","1","ValueType"],"0xA043":["SQ","1","ConceptNameCodeSequence"],"0xA047":["LO","1","MeasurementPrecisionDescriptionTrial"],"0xA050":["CS","1","ContinuityOfContent"],"0xA057":["CS","1-n","UrgencyOrPriorityAlertsTrial"],"0xA060":["LO","1","SequencingIndicatorTrial"],"0xA066":["SQ","1","DocumentIdentifierCodeSequenceTrial"],"0xA067":["PN","1","DocumentAuthorTrial"],"0xA068":["SQ","1","DocumentAuthorIdentifierCodeSequenceTrial"],"0xA070":["SQ","1","IdentifierCodeSequenceTrial"],"0xA073":["SQ","1","VerifyingObserverSequence"],"0xA074":["OB","1","ObjectBinaryIdentifierTrial"],"0xA075":["PN","1","VerifyingObserverName"],"0xA076":["SQ","1","DocumentingObserverIdentifierCodeSequenceTrial"],"0xA078":["SQ","1","AuthorObserverSequence"],"0xA07A":["SQ","1","ParticipantSequence"],"0xA07C":["SQ","1","CustodialOrganizationSequence"],"0xA080":["CS","1","ParticipationType"],"0xA082":["DT","1","ParticipationDateTime"],"0xA084":["CS","1","ObserverType"],"0xA085":["SQ","1","ProcedureIdentifierCodeSequenceTrial"],"0xA088":["SQ","1","VerifyingObserverIdentificationCodeSequence"],"0xA089":["OB","1","ObjectDirectoryBinaryIdentifierTrial"],"0xA090":["SQ","1","EquivalentCDADocumentSequence"],"0xA0B0":["US","2-2n","ReferencedWaveformChannels"],"0xA110":["DA","1","DateOfDocumentOrVerbalTransactionTrial"],"0xA112":["TM","1","TimeOfDocumentCreationOrVerbalTransactionTrial"],"0xA120":["DT","1","DateTime"],"0xA121":["DA","1","Date"],"0xA122":["TM","1","Time"],"0xA123":["PN","1","PersonName"],"0xA124":["UI","1","UID"],"0xA125":["CS","2","ReportStatusIDTrial"],"0xA130":["CS","1","TemporalRangeType"],"0xA132":["UL","1-n","ReferencedSamplePositions"],"0xA136":["US","1-n","ReferencedFrameNumbers"],"0xA138":["DS","1-n","ReferencedTimeOffsets"],"0xA13A":["DT","1-n","ReferencedDateTime"],"0xA160":["UT","1","TextValue"],"0xA161":["FD","1-n","FloatingPointValue"],"0xA162":["SL","1-n","RationalNumeratorValue"],"0xA163":["UL","1-n","RationalDenominatorValue"],"0xA167":["SQ","1","ObservationCategoryCodeSequenceTrial"],"0xA168":["SQ","1","ConceptCodeSequence"],"0xA16A":["ST","1","BibliographicCitationTrial"],"0xA170":["SQ","1","PurposeOfReferenceCodeSequence"],"0xA171":["UI","1","ObservationUID"],"0xA172":["UI","1","ReferencedObservationUIDTrial"],"0xA173":["CS","1","ReferencedObservationClassTrial"],"0xA174":["CS","1","ReferencedObjectObservationClassTrial"],"0xA180":["US","1","AnnotationGroupNumber"],"0xA192":["DA","1","ObservationDateTrial"],"0xA193":["TM","1","ObservationTimeTrial"],"0xA194":["CS","1","MeasurementAutomationTrial"],"0xA195":["SQ","1","ModifierCodeSequence"],"0xA224":["ST","1","IdentificationDescriptionTrial"],"0xA290":["CS","1","CoordinatesSetGeometricTypeTrial"],"0xA296":["SQ","1","AlgorithmCodeSequenceTrial"],"0xA297":["ST","1","AlgorithmDescriptionTrial"],"0xA29A":["SL","2-2n","PixelCoordinatesSetTrial"],"0xA300":["SQ","1","MeasuredValueSequence"],"0xA301":["SQ","1","NumericValueQualifierCodeSequence"],"0xA307":["PN","1","CurrentObserverTrial"],"0xA30A":["DS","1-n","NumericValue"],"0xA313":["SQ","1","ReferencedAccessionSequenceTrial"],"0xA33A":["ST","1","ReportStatusCommentTrial"],"0xA340":["SQ","1","ProcedureContextSequenceTrial"],"0xA352":["PN","1","VerbalSourceTrial"],"0xA353":["ST","1","AddressTrial"],"0xA354":["LO","1","TelephoneNumberTrial"],"0xA358":["SQ","1","VerbalSourceIdentifierCodeSequenceTrial"],"0xA360":["SQ","1","PredecessorDocumentsSequence"],"0xA370":["SQ","1","ReferencedRequestSequence"],"0xA372":["SQ","1","PerformedProcedureCodeSequence"],"0xA375":["SQ","1","CurrentRequestedProcedureEvidenceSequence"],"0xA380":["SQ","1","ReportDetailSequenceTrial"],"0xA385":["SQ","1","PertinentOtherEvidenceSequence"],"0xA390":["SQ","1","HL7StructuredDocumentReferenceSequence"],"0xA402":["UI","1","ObservationSubjectUIDTrial"],"0xA403":["CS","1","ObservationSubjectClassTrial"],"0xA404":["SQ","1","ObservationSubjectTypeCodeSequenceTrial"],"0xA491":["CS","1","CompletionFlag"],"0xA492":["LO","1","CompletionFlagDescription"],"0xA493":["CS","1","VerificationFlag"],"0xA494":["CS","1","ArchiveRequested"],"0xA496":["CS","1","PreliminaryFlag"],"0xA504":["SQ","1","ContentTemplateSequence"],"0xA525":["SQ","1","IdenticalDocumentsSequence"],"0xA600":["CS","1","ObservationSubjectContextFlagTrial"],"0xA601":["CS","1","ObserverContextFlagTrial"],"0xA603":["CS","1","ProcedureContextFlagTrial"],"0xA730":["SQ","1","ContentSequence"],"0xA731":["SQ","1","RelationshipSequenceTrial"],"0xA732":["SQ","1","RelationshipTypeCodeSequenceTrial"],"0xA744":["SQ","1","LanguageCodeSequenceTrial"],"0xA801":["SQ","1","TabulatedValuesSequence"],"0xA802":["UL","1","NumberOfTableRows"],"0xA803":["UL","1","NumberOfTableColumns"],"0xA804":["UL","1","TableRowNumber"],"0xA805":["UL","1","TableColumnNumber"],"0xA806":["SQ","1","TableRowDefinitionSequence"],"0xA807":["SQ","1","TableColumnDefinitionSequence"],"0xA808":["SQ","1","CellValuesSequence"],"0xA992":["ST","1","UniformResourceLocatorTrial"],"0xB020":["SQ","1","WaveformAnnotationSequence"],"0xDB00":["CS","1","TemplateIdentifier"],"0xDB06":["DT","1","TemplateVersion"],"0xDB07":["DT","1","TemplateLocalVersion"],"0xDB0B":["CS","1","TemplateExtensionFlag"],"0xDB0C":["UI","1","TemplateExtensionOrganizationUID"],"0xDB0D":["UI","1","TemplateExtensionCreatorUID"],"0xDB73":["UL","1-n","ReferencedContentItemIdentifier"],"0xE001":["ST","1","HL7InstanceIdentifier"],"0xE004":["DT","1","HL7DocumentEffectiveTime"],"0xE006":["SQ","1","HL7DocumentTypeCodeSequence"],"0xE008":["SQ","1","DocumentClassCodeSequence"],"0xE010":["UR","1","RetrieveURI"],"0xE011":["UI","1","RetrieveLocationUID"],"0xE020":["CS","1","TypeOfInstances"],"0xE021":["SQ","1","DICOMRetrievalSequence"],"0xE022":["SQ","1","DICOMMediaRetrievalSequence"],"0xE023":["SQ","1","WADORetrievalSequence"],"0xE024":["SQ","1","XDSRetrievalSequence"],"0xE025":["SQ","1","WADORSRetrievalSequence"],"0xE030":["UI","1","RepositoryUniqueID"],"0xE031":["UI","1","HomeCommunityID"]},"0x0042":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["ST","1","DocumentTitle"],"0x0011":["OB","1","EncapsulatedDocument"],"0x0012":["LO","1","MIMETypeOfEncapsulatedDocument"],"0x0013":["SQ","1","SourceInstanceSequence"],"0x0014":["LO","1-n","ListOfMIMETypes"],"0x0015":["UL","1","EncapsulatedDocumentLength"]},"0x0044":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["ST","1","ProductPackageIdentifier"],"0x0002":["CS","1","SubstanceAdministrationApproval"],"0x0003":["LT","1","ApprovalStatusFurtherDescription"],"0x0004":["DT","1","ApprovalStatusDateTime"],"0x0007":["SQ","1","ProductTypeCodeSequence"],"0x0008":["LO","1-n","ProductName"],"0x0009":["LT","1","ProductDescription"],"0x000A":["LO","1","ProductLotIdentifier"],"0x000B":["DT","1","ProductExpirationDateTime"],"0x0010":["DT","1","SubstanceAdministrationDateTime"],"0x0011":["LO","1","SubstanceAdministrationNotes"],"0x0012":["LO","1","SubstanceAdministrationDeviceID"],"0x0013":["SQ","1","ProductParameterSequence"],"0x0019":["SQ","1","SubstanceAdministrationParameterSequence"],"0x0100":["SQ","1","ApprovalSequence"],"0x0101":["SQ","1","AssertionCodeSequence"],"0x0102":["UI","1","AssertionUID"],"0x0103":["SQ","1","AsserterIdentificationSequence"],"0x0104":["DT","1","AssertionDateTime"],"0x0105":["DT","1","AssertionExpirationDateTime"],"0x0106":["UT","1","AssertionComments"],"0x0107":["SQ","1","RelatedAssertionSequence"],"0x0108":["UI","1","ReferencedAssertionUID"],"0x0109":["SQ","1","ApprovalSubjectSequence"],"0x010A":["SQ","1","OrganizationalRoleCodeSequence"]},"0x0046":{"0x0000":["UL","1","GenericGroupLength"],"0x0012":["LO","1","LensDescription"],"0x0014":["SQ","1","RightLensSequence"],"0x0015":["SQ","1","LeftLensSequence"],"0x0016":["SQ","1","UnspecifiedLateralityLensSequence"],"0x0018":["SQ","1","CylinderSequence"],"0x0028":["SQ","1","PrismSequence"],"0x0030":["FD","1","HorizontalPrismPower"],"0x0032":["CS","1","HorizontalPrismBase"],"0x0034":["FD","1","VerticalPrismPower"],"0x0036":["CS","1","VerticalPrismBase"],"0x0038":["CS","1","LensSegmentType"],"0x0040":["FD","1","OpticalTransmittance"],"0x0042":["FD","1","ChannelWidth"],"0x0044":["FD","1","PupilSize"],"0x0046":["FD","1","CornealSize"],"0x0047":["SQ","1","CornealSizeSequence"],"0x0050":["SQ","1","AutorefractionRightEyeSequence"],"0x0052":["SQ","1","AutorefractionLeftEyeSequence"],"0x0060":["FD","1","DistancePupillaryDistance"],"0x0062":["FD","1","NearPupillaryDistance"],"0x0063":["FD","1","IntermediatePupillaryDistance"],"0x0064":["FD","1","OtherPupillaryDistance"],"0x0070":["SQ","1","KeratometryRightEyeSequence"],"0x0071":["SQ","1","KeratometryLeftEyeSequence"],"0x0074":["SQ","1","SteepKeratometricAxisSequence"],"0x0075":["FD","1","RadiusOfCurvature"],"0x0076":["FD","1","KeratometricPower"],"0x0077":["FD","1","KeratometricAxis"],"0x0080":["SQ","1","FlatKeratometricAxisSequence"],"0x0092":["CS","1","BackgroundColor"],"0x0094":["CS","1","Optotype"],"0x0095":["CS","1","OptotypePresentation"],"0x0097":["SQ","1","SubjectiveRefractionRightEyeSequence"],"0x0098":["SQ","1","SubjectiveRefractionLeftEyeSequence"],"0x0100":["SQ","1","AddNearSequence"],"0x0101":["SQ","1","AddIntermediateSequence"],"0x0102":["SQ","1","AddOtherSequence"],"0x0104":["FD","1","AddPower"],"0x0106":["FD","1","ViewingDistance"],"0x0110":["SQ","1","CorneaMeasurementsSequence"],"0x0111":["SQ","1","SourceOfCorneaMeasurementDataCodeSequence"],"0x0112":["SQ","1","SteepCornealAxisSequence"],"0x0113":["SQ","1","FlatCornealAxisSequence"],"0x0114":["FD","1","CornealPower"],"0x0115":["FD","1","CornealAxis"],"0x0116":["SQ","1","CorneaMeasurementMethodCodeSequence"],"0x0117":["FL","1","RefractiveIndexOfCornea"],"0x0118":["FL","1","RefractiveIndexOfAqueousHumor"],"0x0121":["SQ","1","VisualAcuityTypeCodeSequence"],"0x0122":["SQ","1","VisualAcuityRightEyeSequence"],"0x0123":["SQ","1","VisualAcuityLeftEyeSequence"],"0x0124":["SQ","1","VisualAcuityBothEyesOpenSequence"],"0x0125":["CS","1","ViewingDistanceType"],"0x0135":["SS","2","VisualAcuityModifiers"],"0x0137":["FD","1","DecimalVisualAcuity"],"0x0139":["LO","1","OptotypeDetailedDefinition"],"0x0145":["SQ","1","ReferencedRefractiveMeasurementsSequence"],"0x0146":["FD","1","SpherePower"],"0x0147":["FD","1","CylinderPower"],"0x0201":["CS","1","CornealTopographySurface"],"0x0202":["FL","2","CornealVertexLocation"],"0x0203":["FL","1","PupilCentroidXCoordinate"],"0x0204":["FL","1","PupilCentroidYCoordinate"],"0x0205":["FL","1","EquivalentPupilRadius"],"0x0207":["SQ","1","CornealTopographyMapTypeCodeSequence"],"0x0208":["IS","2-2n","VerticesOfTheOutlineOfPupil"],"0x0210":["SQ","1","CornealTopographyMappingNormalsSequence"],"0x0211":["SQ","1","MaximumCornealCurvatureSequence"],"0x0212":["FL","1","MaximumCornealCurvature"],"0x0213":["FL","2","MaximumCornealCurvatureLocation"],"0x0215":["SQ","1","MinimumKeratometricSequence"],"0x0218":["SQ","1","SimulatedKeratometricCylinderSequence"],"0x0220":["FL","1","AverageCornealPower"],"0x0224":["FL","1","CornealISValue"],"0x0227":["FL","1","AnalyzedArea"],"0x0230":["FL","1","SurfaceRegularityIndex"],"0x0232":["FL","1","SurfaceAsymmetryIndex"],"0x0234":["FL","1","CornealEccentricityIndex"],"0x0236":["FL","1","KeratoconusPredictionIndex"],"0x0238":["FL","1","DecimalPotentialVisualAcuity"],"0x0242":["CS","1","CornealTopographyMapQualityEvaluation"],"0x0244":["SQ","1","SourceImageCornealProcessedDataSequence"],"0x0247":["FL","3","CornealPointLocation"],"0x0248":["CS","1","CornealPointEstimated"],"0x0249":["FL","1","AxialPower"],"0x0250":["FL","1","TangentialPower"],"0x0251":["FL","1","RefractivePower"],"0x0252":["FL","1","RelativeElevation"],"0x0253":["FL","1","CornealWavefront"]},"0x0048":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["FL","1","ImagedVolumeWidth"],"0x0002":["FL","1","ImagedVolumeHeight"],"0x0003":["FL","1","ImagedVolumeDepth"],"0x0006":["UL","1","TotalPixelMatrixColumns"],"0x0007":["UL","1","TotalPixelMatrixRows"],"0x0008":["SQ","1","TotalPixelMatrixOriginSequence"],"0x0010":["CS","1","SpecimenLabelInImage"],"0x0011":["CS","1","FocusMethod"],"0x0012":["CS","1","ExtendedDepthOfField"],"0x0013":["US","1","NumberOfFocalPlanes"],"0x0014":["FL","1","DistanceBetweenFocalPlanes"],"0x0015":["US","3","RecommendedAbsentPixelCIELabValue"],"0x0100":["SQ","1","IlluminatorTypeCodeSequence"],"0x0102":["DS","6","ImageOrientationSlide"],"0x0105":["SQ","1","OpticalPathSequence"],"0x0106":["SH","1","OpticalPathIdentifier"],"0x0107":["ST","1","OpticalPathDescription"],"0x0108":["SQ","1","IlluminationColorCodeSequence"],"0x0110":["SQ","1","SpecimenReferenceSequence"],"0x0111":["DS","1","CondenserLensPower"],"0x0112":["DS","1","ObjectiveLensPower"],"0x0113":["DS","1","ObjectiveLensNumericalAperture"],"0x0120":["SQ","1","PaletteColorLookupTableSequence"],"0x0200":["SQ","1","ReferencedImageNavigationSequence"],"0x0201":["US","2","TopLeftHandCornerOfLocalizerArea"],"0x0202":["US","2","BottomRightHandCornerOfLocalizerArea"],"0x0207":["SQ","1","OpticalPathIdentificationSequence"],"0x021A":["SQ","1","PlanePositionSlideSequence"],"0x021E":["SL","1","ColumnPositionInTotalImagePixelMatrix"],"0x021F":["SL","1","RowPositionInTotalImagePixelMatrix"],"0x0301":["CS","1","PixelOriginInterpretation"],"0x0302":["UL","1","NumberOfOpticalPaths"],"0x0303":["UL","1","TotalPixelMatrixFocalPlanes"]},"0x0050":{"0x0000":["UL","1","GenericGroupLength"],"0x0004":["CS","1","CalibrationImage"],"0x0010":["SQ","1","DeviceSequence"],"0x0012":["SQ","1","ContainerComponentTypeCodeSequence"],"0x0013":["FD","1","ContainerComponentThickness"],"0x0014":["DS","1","DeviceLength"],"0x0015":["FD","1","ContainerComponentWidth"],"0x0016":["DS","1","DeviceDiameter"],"0x0017":["CS","1","DeviceDiameterUnits"],"0x0018":["DS","1","DeviceVolume"],"0x0019":["DS","1","InterMarkerDistance"],"0x001A":["CS","1","ContainerComponentMaterial"],"0x001B":["LO","1","ContainerComponentID"],"0x001C":["FD","1","ContainerComponentLength"],"0x001D":["FD","1","ContainerComponentDiameter"],"0x001E":["LO","1","ContainerComponentDescription"],"0x0020":["LO","1","DeviceDescription"],"0x0021":["ST","1","LongDeviceDescription"]},"0x0052":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["FL","1","ContrastBolusIngredientPercentByVolume"],"0x0002":["FD","1","OCTFocalDistance"],"0x0003":["FD","1","BeamSpotSize"],"0x0004":["FD","1","EffectiveRefractiveIndex"],"0x0006":["CS","1","OCTAcquisitionDomain"],"0x0007":["FD","1","OCTOpticalCenterWavelength"],"0x0008":["FD","1","AxialResolution"],"0x0009":["FD","1","RangingDepth"],"0x0011":["FD","1","ALineRate"],"0x0012":["US","1","ALinesPerFrame"],"0x0013":["FD","1","CatheterRotationalRate"],"0x0014":["FD","1","ALinePixelSpacing"],"0x0016":["SQ","1","ModeOfPercutaneousAccessSequence"],"0x0025":["SQ","1","IntravascularOCTFrameTypeSequence"],"0x0026":["CS","1","OCTZOffsetApplied"],"0x0027":["SQ","1","IntravascularFrameContentSequence"],"0x0028":["FD","1","IntravascularLongitudinalDistance"],"0x0029":["SQ","1","IntravascularOCTFrameContentSequence"],"0x0030":["SS","1","OCTZOffsetCorrection"],"0x0031":["CS","1","CatheterDirectionOfRotation"],"0x0033":["FD","1","SeamLineLocation"],"0x0034":["FD","1","FirstALineLocation"],"0x0036":["US","1","SeamLineIndex"],"0x0038":["US","1","NumberOfPaddedALines"],"0x0039":["CS","1","InterpolationType"],"0x003A":["CS","1","RefractiveIndexApplied"]},"0x0054":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["US","1-n","EnergyWindowVector"],"0x0011":["US","1","NumberOfEnergyWindows"],"0x0012":["SQ","1","EnergyWindowInformationSequence"],"0x0013":["SQ","1","EnergyWindowRangeSequence"],"0x0014":["DS","1","EnergyWindowLowerLimit"],"0x0015":["DS","1","EnergyWindowUpperLimit"],"0x0016":["SQ","1","RadiopharmaceuticalInformationSequence"],"0x0017":["IS","1","ResidualSyringeCounts"],"0x0018":["SH","1","EnergyWindowName"],"0x0020":["US","1-n","DetectorVector"],"0x0021":["US","1","NumberOfDetectors"],"0x0022":["SQ","1","DetectorInformationSequence"],"0x0030":["US","1-n","PhaseVector"],"0x0031":["US","1","NumberOfPhases"],"0x0032":["SQ","1","PhaseInformationSequence"],"0x0033":["US","1","NumberOfFramesInPhase"],"0x0036":["IS","1","PhaseDelay"],"0x0038":["IS","1","PauseBetweenFrames"],"0x0039":["CS","1","PhaseDescription"],"0x0050":["US","1-n","RotationVector"],"0x0051":["US","1","NumberOfRotations"],"0x0052":["SQ","1","RotationInformationSequence"],"0x0053":["US","1","NumberOfFramesInRotation"],"0x0060":["US","1-n","RRIntervalVector"],"0x0061":["US","1","NumberOfRRIntervals"],"0x0062":["SQ","1","GatedInformationSequence"],"0x0063":["SQ","1","DataInformationSequence"],"0x0070":["US","1-n","TimeSlotVector"],"0x0071":["US","1","NumberOfTimeSlots"],"0x0072":["SQ","1","TimeSlotInformationSequence"],"0x0073":["DS","1","TimeSlotTime"],"0x0080":["US","1-n","SliceVector"],"0x0081":["US","1","NumberOfSlices"],"0x0090":["US","1-n","AngularViewVector"],"0x0100":["US","1-n","TimeSliceVector"],"0x0101":["US","1","NumberOfTimeSlices"],"0x0200":["DS","1","StartAngle"],"0x0202":["CS","1","TypeOfDetectorMotion"],"0x0210":["IS","1-n","TriggerVector"],"0x0211":["US","1","NumberOfTriggersInPhase"],"0x0220":["SQ","1","ViewCodeSequence"],"0x0222":["SQ","1","ViewModifierCodeSequence"],"0x0300":["SQ","1","RadionuclideCodeSequence"],"0x0302":["SQ","1","AdministrationRouteCodeSequence"],"0x0304":["SQ","1","RadiopharmaceuticalCodeSequence"],"0x0306":["SQ","1","CalibrationDataSequence"],"0x0308":["US","1","EnergyWindowNumber"],"0x0400":["SH","1","ImageID"],"0x0410":["SQ","1","PatientOrientationCodeSequence"],"0x0412":["SQ","1","PatientOrientationModifierCodeSequence"],"0x0414":["SQ","1","PatientGantryRelationshipCodeSequence"],"0x0500":["CS","1","SliceProgressionDirection"],"0x0501":["CS","1","ScanProgressionDirection"],"0x1000":["CS","2","SeriesType"],"0x1001":["CS","1","Units"],"0x1002":["CS","1","CountsSource"],"0x1004":["CS","1","ReprojectionMethod"],"0x1006":["CS","1","SUVType"],"0x1100":["CS","1","RandomsCorrectionMethod"],"0x1101":["LO","1","AttenuationCorrectionMethod"],"0x1102":["CS","1","DecayCorrection"],"0x1103":["LO","1","ReconstructionMethod"],"0x1104":["LO","1","DetectorLinesOfResponseUsed"],"0x1105":["LO","1","ScatterCorrectionMethod"],"0x1200":["DS","1","AxialAcceptance"],"0x1201":["IS","2","AxialMash"],"0x1202":["IS","1","TransverseMash"],"0x1203":["DS","2","DetectorElementSize"],"0x1210":["DS","1","CoincidenceWindowWidth"],"0x1220":["CS","1-n","SecondaryCountsType"],"0x1300":["DS","1","FrameReferenceTime"],"0x1310":["IS","1","PrimaryPromptsCountsAccumulated"],"0x1311":["IS","1-n","SecondaryCountsAccumulated"],"0x1320":["DS","1","SliceSensitivityFactor"],"0x1321":["DS","1","DecayFactor"],"0x1322":["DS","1","DoseCalibrationFactor"],"0x1323":["DS","1","ScatterFractionFactor"],"0x1324":["DS","1","DeadTimeFactor"],"0x1330":["US","1","ImageIndex"],"0x1400":["CS","1-n","CountsIncluded"],"0x1401":["CS","1","DeadTimeCorrectionFlag"]},"0x0060":{"0x0000":["UL","1","GenericGroupLength"],"0x3000":["SQ","1","HistogramSequence"],"0x3002":["US","1","HistogramNumberOfBins"],"0x3004":["xs","1","HistogramFirstBinValue"],"0x3006":["xs","1","HistogramLastBinValue"],"0x3008":["US","1","HistogramBinWidth"],"0x3010":["LO","1","HistogramExplanation"],"0x3020":["UL","1-n","HistogramData"]},"0x0062":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["CS","1","SegmentationType"],"0x0002":["SQ","1","SegmentSequence"],"0x0003":["SQ","1","SegmentedPropertyCategoryCodeSequence"],"0x0004":["US","1","SegmentNumber"],"0x0005":["LO","1","SegmentLabel"],"0x0006":["ST","1","SegmentDescription"],"0x0007":["SQ","1","SegmentationAlgorithmIdentificationSequence"],"0x0008":["CS","1","SegmentAlgorithmType"],"0x0009":["LO","1-n","SegmentAlgorithmName"],"0x000A":["SQ","1","SegmentIdentificationSequence"],"0x000B":["US","1-n","ReferencedSegmentNumber"],"0x000C":["US","1","RecommendedDisplayGrayscaleValue"],"0x000D":["US","3","RecommendedDisplayCIELabValue"],"0x000E":["US","1","MaximumFractionalValue"],"0x000F":["SQ","1","SegmentedPropertyTypeCodeSequence"],"0x0010":["CS","1","SegmentationFractionalType"],"0x0011":["SQ","1","SegmentedPropertyTypeModifierCodeSequence"],"0x0012":["SQ","1","UsedSegmentsSequence"],"0x0013":["CS","1","SegmentsOverlap"],"0x0020":["UT","1","TrackingID"],"0x0021":["UI","1","TrackingUID"]},"0x0064":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["SQ","1","DeformableRegistrationSequence"],"0x0003":["UI","1","SourceFrameOfReferenceUID"],"0x0005":["SQ","1","DeformableRegistrationGridSequence"],"0x0007":["UL","3","GridDimensions"],"0x0008":["FD","3","GridResolution"],"0x0009":["OF","1","VectorGridData"],"0x000F":["SQ","1","PreDeformationMatrixRegistrationSequence"],"0x0010":["SQ","1","PostDeformationMatrixRegistrationSequence"]},"0x0066":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["UL","1","NumberOfSurfaces"],"0x0002":["SQ","1","SurfaceSequence"],"0x0003":["UL","1","SurfaceNumber"],"0x0004":["LT","1","SurfaceComments"],"0x0009":["CS","1","SurfaceProcessing"],"0x000A":["FL","1","SurfaceProcessingRatio"],"0x000B":["LO","1","SurfaceProcessingDescription"],"0x000C":["FL","1","RecommendedPresentationOpacity"],"0x000D":["CS","1","RecommendedPresentationType"],"0x000E":["CS","1","FiniteVolume"],"0x0010":["CS","1","Manifold"],"0x0011":["SQ","1","SurfacePointsSequence"],"0x0012":["SQ","1","SurfacePointsNormalsSequence"],"0x0013":["SQ","1","SurfaceMeshPrimitivesSequence"],"0x0015":["UL","1","NumberOfSurfacePoints"],"0x0016":["OF","1","PointCoordinatesData"],"0x0017":["FL","3","PointPositionAccuracy"],"0x0018":["FL","1","MeanPointDistance"],"0x0019":["FL","1","MaximumPointDistance"],"0x001A":["FL","6","PointsBoundingBoxCoordinates"],"0x001B":["FL","3","AxisOfRotation"],"0x001C":["FL","3","CenterOfRotation"],"0x001E":["UL","1","NumberOfVectors"],"0x001F":["US","1","VectorDimensionality"],"0x0020":["FL","1-n","VectorAccuracy"],"0x0021":["OF","1","VectorCoordinateData"],"0x0022":["OD","1","DoublePointCoordinatesData"],"0x0023":["OW","1","TrianglePointIndexList"],"0x0024":["OW","1","EdgePointIndexList"],"0x0025":["OW","1","VertexPointIndexList"],"0x0026":["SQ","1","TriangleStripSequence"],"0x0027":["SQ","1","TriangleFanSequence"],"0x0028":["SQ","1","LineSequence"],"0x0029":["OW","1","PrimitivePointIndexList"],"0x002A":["UL","1","SurfaceCount"],"0x002B":["SQ","1","ReferencedSurfaceSequence"],"0x002C":["UL","1","ReferencedSurfaceNumber"],"0x002D":["SQ","1","SegmentSurfaceGenerationAlgorithmIdentificationSequence"],"0x002E":["SQ","1","SegmentSurfaceSourceInstanceSequence"],"0x002F":["SQ","1","AlgorithmFamilyCodeSequence"],"0x0030":["SQ","1","AlgorithmNameCodeSequence"],"0x0031":["LO","1","AlgorithmVersion"],"0x0032":["LT","1","AlgorithmParameters"],"0x0034":["SQ","1","FacetSequence"],"0x0035":["SQ","1","SurfaceProcessingAlgorithmIdentificationSequence"],"0x0036":["LO","1","AlgorithmName"],"0x0037":["FL","1","RecommendedPointRadius"],"0x0038":["FL","1","RecommendedLineThickness"],"0x0040":["OL","1","LongPrimitivePointIndexList"],"0x0041":["OL","1","LongTrianglePointIndexList"],"0x0042":["OL","1","LongEdgePointIndexList"],"0x0043":["OL","1","LongVertexPointIndexList"],"0x0101":["SQ","1","TrackSetSequence"],"0x0102":["SQ","1","TrackSequence"],"0x0103":["OW","1","RecommendedDisplayCIELabValueList"],"0x0104":["SQ","1","TrackingAlgorithmIdentificationSequence"],"0x0105":["UL","1","TrackSetNumber"],"0x0106":["LO","1","TrackSetLabel"],"0x0107":["UT","1","TrackSetDescription"],"0x0108":["SQ","1","TrackSetAnatomicalTypeCodeSequence"],"0x0121":["SQ","1","MeasurementsSequence"],"0x0124":["SQ","1","TrackSetStatisticsSequence"],"0x0125":["OF","1","FloatingPointValues"],"0x0129":["OL","1","TrackPointIndexList"],"0x0130":["SQ","1","TrackStatisticsSequence"],"0x0132":["SQ","1","MeasurementValuesSequence"],"0x0133":["SQ","1","DiffusionAcquisitionCodeSequence"],"0x0134":["SQ","1","DiffusionModelCodeSequence"]},"0x0068":{"0x0000":["UL","1","GenericGroupLength"],"0x6210":["LO","1","ImplantSize"],"0x6221":["LO","1","ImplantTemplateVersion"],"0x6222":["SQ","1","ReplacedImplantTemplateSequence"],"0x6223":["CS","1","ImplantType"],"0x6224":["SQ","1","DerivationImplantTemplateSequence"],"0x6225":["SQ","1","OriginalImplantTemplateSequence"],"0x6226":["DT","1","EffectiveDateTime"],"0x6230":["SQ","1","ImplantTargetAnatomySequence"],"0x6260":["SQ","1","InformationFromManufacturerSequence"],"0x6265":["SQ","1","NotificationFromManufacturerSequence"],"0x6270":["DT","1","InformationIssueDateTime"],"0x6280":["ST","1","InformationSummary"],"0x62A0":["SQ","1","ImplantRegulatoryDisapprovalCodeSequence"],"0x62A5":["FD","1","OverallTemplateSpatialTolerance"],"0x62C0":["SQ","1","HPGLDocumentSequence"],"0x62D0":["US","1","HPGLDocumentID"],"0x62D5":["LO","1","HPGLDocumentLabel"],"0x62E0":["SQ","1","ViewOrientationCodeSequence"],"0x62F0":["SQ","1","ViewOrientationModifierCodeSequence"],"0x62F2":["FD","1","HPGLDocumentScaling"],"0x6300":["OB","1","HPGLDocument"],"0x6310":["US","1","HPGLContourPenNumber"],"0x6320":["SQ","1","HPGLPenSequence"],"0x6330":["US","1","HPGLPenNumber"],"0x6340":["LO","1","HPGLPenLabel"],"0x6345":["ST","1","HPGLPenDescription"],"0x6346":["FD","2","RecommendedRotationPoint"],"0x6347":["FD","4","BoundingRectangle"],"0x6350":["US","1-n","ImplantTemplate3DModelSurfaceNumber"],"0x6360":["SQ","1","SurfaceModelDescriptionSequence"],"0x6380":["LO","1","SurfaceModelLabel"],"0x6390":["FD","1","SurfaceModelScalingFactor"],"0x63A0":["SQ","1","MaterialsCodeSequence"],"0x63A4":["SQ","1","CoatingMaterialsCodeSequence"],"0x63A8":["SQ","1","ImplantTypeCodeSequence"],"0x63AC":["SQ","1","FixationMethodCodeSequence"],"0x63B0":["SQ","1","MatingFeatureSetsSequence"],"0x63C0":["US","1","MatingFeatureSetID"],"0x63D0":["LO","1","MatingFeatureSetLabel"],"0x63E0":["SQ","1","MatingFeatureSequence"],"0x63F0":["US","1","MatingFeatureID"],"0x6400":["SQ","1","MatingFeatureDegreeOfFreedomSequence"],"0x6410":["US","1","DegreeOfFreedomID"],"0x6420":["CS","1","DegreeOfFreedomType"],"0x6430":["SQ","1","TwoDMatingFeatureCoordinatesSequence"],"0x6440":["US","1","ReferencedHPGLDocumentID"],"0x6450":["FD","2","TwoDMatingPoint"],"0x6460":["FD","4","TwoDMatingAxes"],"0x6470":["SQ","1","TwoDDegreeOfFreedomSequence"],"0x6490":["FD","3","ThreeDDegreeOfFreedomAxis"],"0x64A0":["FD","2","RangeOfFreedom"],"0x64C0":["FD","3","ThreeDMatingPoint"],"0x64D0":["FD","9","ThreeDMatingAxes"],"0x64F0":["FD","3","TwoDDegreeOfFreedomAxis"],"0x6500":["SQ","1","PlanningLandmarkPointSequence"],"0x6510":["SQ","1","PlanningLandmarkLineSequence"],"0x6520":["SQ","1","PlanningLandmarkPlaneSequence"],"0x6530":["US","1","PlanningLandmarkID"],"0x6540":["LO","1","PlanningLandmarkDescription"],"0x6545":["SQ","1","PlanningLandmarkIdentificationCodeSequence"],"0x6550":["SQ","1","TwoDPointCoordinatesSequence"],"0x6560":["FD","2","TwoDPointCoordinates"],"0x6590":["FD","3","ThreeDPointCoordinates"],"0x65A0":["SQ","1","TwoDLineCoordinatesSequence"],"0x65B0":["FD","4","TwoDLineCoordinates"],"0x65D0":["FD","6","ThreeDLineCoordinates"],"0x65E0":["SQ","1","TwoDPlaneCoordinatesSequence"],"0x65F0":["FD","4","TwoDPlaneIntersection"],"0x6610":["FD","3","ThreeDPlaneOrigin"],"0x6620":["FD","3","ThreeDPlaneNormal"],"0x7001":["CS","1","ModelModification"],"0x7002":["CS","1","ModelMirroring"],"0x7003":["SQ","1","ModelUsageCodeSequence"],"0x7004":["UI","1","ModelGroupUID"],"0x7005":["UR","1","RelativeURIReferenceWithinEncapsulatedDocument"]},"0x006A":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["CS","1","AnnotationCoordinateType"],"0x0002":["SQ","1","AnnotationGroupSequence"],"0x0003":["UI","1","AnnotationGroupUID"],"0x0005":["LO","1","AnnotationGroupLabel"],"0x0006":["UT","1","AnnotationGroupDescription"],"0x0007":["CS","1","AnnotationGroupGenerationType"],"0x0008":["SQ","1","AnnotationGroupAlgorithmIdentificationSequence"],"0x0009":["SQ","1","AnnotationPropertyCategoryCodeSequence"],"0x000A":["SQ","1","AnnotationPropertyTypeCodeSequence"],"0x000B":["SQ","1","AnnotationPropertyTypeModifierCodeSequence"],"0x000C":["UL","1","NumberOfAnnotations"],"0x000D":["CS","1","AnnotationAppliesToAllOpticalPaths"],"0x000E":["SH","1-n","ReferencedOpticalPathIdentifier"],"0x000F":["CS","1","AnnotationAppliesToAllZPlanes"],"0x0010":["FD","1-n","CommonZCoordinateValue"],"0x0011":["OL","1","AnnotationIndexList"]},"0x0070":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["SQ","1","GraphicAnnotationSequence"],"0x0002":["CS","1","GraphicLayer"],"0x0003":["CS","1","BoundingBoxAnnotationUnits"],"0x0004":["CS","1","AnchorPointAnnotationUnits"],"0x0005":["CS","1","GraphicAnnotationUnits"],"0x0006":["ST","1","UnformattedTextValue"],"0x0008":["SQ","1","TextObjectSequence"],"0x0009":["SQ","1","GraphicObjectSequence"],"0x0010":["FL","2","BoundingBoxTopLeftHandCorner"],"0x0011":["FL","2","BoundingBoxBottomRightHandCorner"],"0x0012":["CS","1","BoundingBoxTextHorizontalJustification"],"0x0014":["FL","2","AnchorPoint"],"0x0015":["CS","1","AnchorPointVisibility"],"0x0020":["US","1","GraphicDimensions"],"0x0021":["US","1","NumberOfGraphicPoints"],"0x0022":["FL","2-n","GraphicData"],"0x0023":["CS","1","GraphicType"],"0x0024":["CS","1","GraphicFilled"],"0x0040":["IS","1","ImageRotationRetired"],"0x0041":["CS","1","ImageHorizontalFlip"],"0x0042":["US","1","ImageRotation"],"0x0050":["US","2","DisplayedAreaTopLeftHandCornerTrial"],"0x0051":["US","2","DisplayedAreaBottomRightHandCornerTrial"],"0x0052":["SL","2","DisplayedAreaTopLeftHandCorner"],"0x0053":["SL","2","DisplayedAreaBottomRightHandCorner"],"0x005A":["SQ","1","DisplayedAreaSelectionSequence"],"0x0060":["SQ","1","GraphicLayerSequence"],"0x0062":["IS","1","GraphicLayerOrder"],"0x0066":["US","1","GraphicLayerRecommendedDisplayGrayscaleValue"],"0x0067":["US","3","GraphicLayerRecommendedDisplayRGBValue"],"0x0068":["LO","1","GraphicLayerDescription"],"0x0080":["CS","1","ContentLabel"],"0x0081":["LO","1","ContentDescription"],"0x0082":["DA","1","PresentationCreationDate"],"0x0083":["TM","1","PresentationCreationTime"],"0x0084":["PN","1","ContentCreatorName"],"0x0086":["SQ","1","ContentCreatorIdentificationCodeSequence"],"0x0087":["SQ","1","AlternateContentDescriptionSequence"],"0x0100":["CS","1","PresentationSizeMode"],"0x0101":["DS","2","PresentationPixelSpacing"],"0x0102":["IS","2","PresentationPixelAspectRatio"],"0x0103":["FL","1","PresentationPixelMagnificationRatio"],"0x0207":["LO","1","GraphicGroupLabel"],"0x0208":["ST","1","GraphicGroupDescription"],"0x0209":["SQ","1","CompoundGraphicSequence"],"0x0226":["UL","1","CompoundGraphicInstanceID"],"0x0227":["LO","1","FontName"],"0x0228":["CS","1","FontNameType"],"0x0229":["LO","1","CSSFontName"],"0x0230":["FD","1","RotationAngle"],"0x0231":["SQ","1","TextStyleSequence"],"0x0232":["SQ","1","LineStyleSequence"],"0x0233":["SQ","1","FillStyleSequence"],"0x0234":["SQ","1","GraphicGroupSequence"],"0x0241":["US","3","TextColorCIELabValue"],"0x0242":["CS","1","HorizontalAlignment"],"0x0243":["CS","1","VerticalAlignment"],"0x0244":["CS","1","ShadowStyle"],"0x0245":["FL","1","ShadowOffsetX"],"0x0246":["FL","1","ShadowOffsetY"],"0x0247":["US","3","ShadowColorCIELabValue"],"0x0248":["CS","1","Underlined"],"0x0249":["CS","1","Bold"],"0x0250":["CS","1","Italic"],"0x0251":["US","3","PatternOnColorCIELabValue"],"0x0252":["US","3","PatternOffColorCIELabValue"],"0x0253":["FL","1","LineThickness"],"0x0254":["CS","1","LineDashingStyle"],"0x0255":["UL","1","LinePattern"],"0x0256":["OB","1","FillPattern"],"0x0257":["CS","1","FillMode"],"0x0258":["FL","1","ShadowOpacity"],"0x0261":["FL","1","GapLength"],"0x0262":["FL","1","DiameterOfVisibility"],"0x0273":["FL","2","RotationPoint"],"0x0274":["CS","1","TickAlignment"],"0x0278":["CS","1","ShowTickLabel"],"0x0279":["CS","1","TickLabelAlignment"],"0x0282":["CS","1","CompoundGraphicUnits"],"0x0284":["FL","1","PatternOnOpacity"],"0x0285":["FL","1","PatternOffOpacity"],"0x0287":["SQ","1","MajorTicksSequence"],"0x0288":["FL","1","TickPosition"],"0x0289":["SH","1","TickLabel"],"0x0294":["CS","1","CompoundGraphicType"],"0x0295":["UL","1","GraphicGroupID"],"0x0306":["CS","1","ShapeType"],"0x0308":["SQ","1","RegistrationSequence"],"0x0309":["SQ","1","MatrixRegistrationSequence"],"0x030A":["SQ","1","MatrixSequence"],"0x030B":["FD","16","FrameOfReferenceToDisplayedCoordinateSystemTransformationMatrix"],"0x030C":["CS","1","FrameOfReferenceTransformationMatrixType"],"0x030D":["SQ","1","RegistrationTypeCodeSequence"],"0x030F":["ST","1","FiducialDescription"],"0x0310":["SH","1","FiducialIdentifier"],"0x0311":["SQ","1","FiducialIdentifierCodeSequence"],"0x0312":["FD","1","ContourUncertaintyRadius"],"0x0314":["SQ","1","UsedFiducialsSequence"],"0x0318":["SQ","1","GraphicCoordinatesDataSequence"],"0x031A":["UI","1","FiducialUID"],"0x031B":["UI","1","ReferencedFiducialUID"],"0x031C":["SQ","1","FiducialSetSequence"],"0x031E":["SQ","1","FiducialSequence"],"0x031F":["SQ","1","FiducialsPropertyCategoryCodeSequence"],"0x0401":["US","3","GraphicLayerRecommendedDisplayCIELabValue"],"0x0402":["SQ","1","BlendingSequence"],"0x0403":["FL","1","RelativeOpacity"],"0x0404":["SQ","1","ReferencedSpatialRegistrationSequence"],"0x0405":["CS","1","BlendingPosition"],"0x1101":["UI","1","PresentationDisplayCollectionUID"],"0x1102":["UI","1","PresentationSequenceCollectionUID"],"0x1103":["US","1","PresentationSequencePositionIndex"],"0x1104":["SQ","1","RenderedImageReferenceSequence"],"0x1201":["SQ","1","VolumetricPresentationStateInputSequence"],"0x1202":["CS","1","PresentationInputType"],"0x1203":["US","1","InputSequencePositionIndex"],"0x1204":["CS","1","Crop"],"0x1205":["US","1-n","CroppingSpecificationIndex"],"0x1206":["CS","1","CompositingMethod"],"0x1207":["US","1","VolumetricPresentationInputNumber"],"0x1208":["CS","1","ImageVolumeGeometry"],"0x1209":["UI","1","VolumetricPresentationInputSetUID"],"0x120A":["SQ","1","VolumetricPresentationInputSetSequence"],"0x120B":["CS","1","GlobalCrop"],"0x120C":["US","1-n","GlobalCroppingSpecificationIndex"],"0x120D":["CS","1","RenderingMethod"],"0x1301":["SQ","1","VolumeCroppingSequence"],"0x1302":["CS","1","VolumeCroppingMethod"],"0x1303":["FD","6","BoundingBoxCrop"],"0x1304":["SQ","1","ObliqueCroppingPlaneSequence"],"0x1305":["FD","4","Plane"],"0x1306":["FD","3","PlaneNormal"],"0x1309":["US","1","CroppingSpecificationNumber"],"0x1501":["CS","1","MultiPlanarReconstructionStyle"],"0x1502":["CS","1","MPRThicknessType"],"0x1503":["FD","1","MPRSlabThickness"],"0x1505":["FD","3","MPRTopLeftHandCorner"],"0x1507":["FD","3","MPRViewWidthDirection"],"0x1508":["FD","1","MPRViewWidth"],"0x150C":["UL","1","NumberOfVolumetricCurvePoints"],"0x150D":["OD","1","VolumetricCurvePoints"],"0x1511":["FD","3","MPRViewHeightDirection"],"0x1512":["FD","1","MPRViewHeight"],"0x1602":["CS","1","RenderProjection"],"0x1603":["FD","3","ViewpointPosition"],"0x1604":["FD","3","ViewpointLookAtPoint"],"0x1605":["FD","3","ViewpointUpDirection"],"0x1606":["FD","6","RenderFieldOfView"],"0x1607":["FD","1","SamplingStepSize"],"0x1701":["CS","1","ShadingStyle"],"0x1702":["FD","1","AmbientReflectionIntensity"],"0x1703":["FD","3","LightDirection"],"0x1704":["FD","1","DiffuseReflectionIntensity"],"0x1705":["FD","1","SpecularReflectionIntensity"],"0x1706":["FD","1","Shininess"],"0x1801":["SQ","1","PresentationStateClassificationComponentSequence"],"0x1802":["CS","1","ComponentType"],"0x1803":["SQ","1","ComponentInputSequence"],"0x1804":["US","1","VolumetricPresentationInputIndex"],"0x1805":["SQ","1","PresentationStateCompositorComponentSequence"],"0x1806":["SQ","1","WeightingTransferFunctionSequence"],"0x1807":["US","3","WeightingLookupTableDescriptor"],"0x1808":["OB","1","WeightingLookupTableData"],"0x1901":["SQ","1","VolumetricAnnotationSequence"],"0x1903":["SQ","1","ReferencedStructuredContextSequence"],"0x1904":["UI","1","ReferencedContentItem"],"0x1905":["SQ","1","VolumetricPresentationInputAnnotationSequence"],"0x1907":["CS","1","AnnotationClipping"],"0x1A01":["CS","1","PresentationAnimationStyle"],"0x1A03":["FD","1","RecommendedAnimationRate"],"0x1A04":["SQ","1","AnimationCurveSequence"],"0x1A05":["FD","1","AnimationStepSize"],"0x1A06":["FD","1","SwivelRange"],"0x1A07":["OD","1","VolumetricCurveUpDirections"],"0x1A08":["SQ","1","VolumeStreamSequence"],"0x1A09":["LO","1","RGBATransferFunctionDescription"],"0x1B01":["SQ","1","AdvancedBlendingSequence"],"0x1B02":["US","1","BlendingInputNumber"],"0x1B03":["SQ","1","BlendingDisplayInputSequence"],"0x1B04":["SQ","1","BlendingDisplaySequence"],"0x1B06":["CS","1","BlendingMode"],"0x1B07":["CS","1","TimeSeriesBlending"],"0x1B08":["CS","1","GeometryForDisplay"],"0x1B11":["SQ","1","ThresholdSequence"],"0x1B12":["SQ","1","ThresholdValueSequence"],"0x1B13":["CS","1","ThresholdType"],"0x1B14":["FD","1","ThresholdValue"]},"0x0072":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["SH","1","HangingProtocolName"],"0x0004":["LO","1","HangingProtocolDescription"],"0x0006":["CS","1","HangingProtocolLevel"],"0x0008":["LO","1","HangingProtocolCreator"],"0x000A":["DT","1","HangingProtocolCreationDateTime"],"0x000C":["SQ","1","HangingProtocolDefinitionSequence"],"0x000E":["SQ","1","HangingProtocolUserIdentificationCodeSequence"],"0x0010":["LO","1","HangingProtocolUserGroupName"],"0x0012":["SQ","1","SourceHangingProtocolSequence"],"0x0014":["US","1","NumberOfPriorsReferenced"],"0x0020":["SQ","1","ImageSetsSequence"],"0x0022":["SQ","1","ImageSetSelectorSequence"],"0x0024":["CS","1","ImageSetSelectorUsageFlag"],"0x0026":["AT","1","SelectorAttribute"],"0x0028":["US","1","SelectorValueNumber"],"0x0030":["SQ","1","TimeBasedImageSetsSequence"],"0x0032":["US","1","ImageSetNumber"],"0x0034":["CS","1","ImageSetSelectorCategory"],"0x0038":["US","2","RelativeTime"],"0x003A":["CS","1","RelativeTimeUnits"],"0x003C":["SS","2","AbstractPriorValue"],"0x003E":["SQ","1","AbstractPriorCodeSequence"],"0x0040":["LO","1","ImageSetLabel"],"0x0050":["CS","1","SelectorAttributeVR"],"0x0052":["AT","1-n","SelectorSequencePointer"],"0x0054":["LO","1-n","SelectorSequencePointerPrivateCreator"],"0x0056":["LO","1","SelectorAttributePrivateCreator"],"0x005E":["AE","1-n","SelectorAEValue"],"0x005F":["AS","1-n","SelectorASValue"],"0x0060":["AT","1-n","SelectorATValue"],"0x0061":["DA","1-n","SelectorDAValue"],"0x0062":["CS","1-n","SelectorCSValue"],"0x0063":["DT","1-n","SelectorDTValue"],"0x0064":["IS","1-n","SelectorISValue"],"0x0065":["OB","1","SelectorOBValue"],"0x0066":["LO","1-n","SelectorLOValue"],"0x0067":["OF","1","SelectorOFValue"],"0x0068":["LT","1","SelectorLTValue"],"0x0069":["OW","1","SelectorOWValue"],"0x006A":["PN","1-n","SelectorPNValue"],"0x006B":["TM","1-n","SelectorTMValue"],"0x006C":["SH","1-n","SelectorSHValue"],"0x006D":["UN","1","SelectorUNValue"],"0x006E":["ST","1","SelectorSTValue"],"0x006F":["UC","1-n","SelectorUCValue"],"0x0070":["UT","1","SelectorUTValue"],"0x0071":["UR","1","SelectorURValue"],"0x0072":["DS","1-n","SelectorDSValue"],"0x0073":["OD","1","SelectorODValue"],"0x0074":["FD","1-n","SelectorFDValue"],"0x0075":["OL","1","SelectorOLValue"],"0x0076":["FL","1-n","SelectorFLValue"],"0x0078":["UL","1-n","SelectorULValue"],"0x007A":["US","1-n","SelectorUSValue"],"0x007C":["SL","1-n","SelectorSLValue"],"0x007E":["SS","1-n","SelectorSSValue"],"0x007F":["UI","1-n","SelectorUIValue"],"0x0080":["SQ","1","SelectorCodeSequenceValue"],"0x0081":["OV","1","SelectorOVValue"],"0x0082":["SV","1-n","SelectorSVValue"],"0x0083":["UV","1-n","SelectorUVValue"],"0x0100":["US","1","NumberOfScreens"],"0x0102":["SQ","1","NominalScreenDefinitionSequence"],"0x0104":["US","1","NumberOfVerticalPixels"],"0x0106":["US","1","NumberOfHorizontalPixels"],"0x0108":["FD","4","DisplayEnvironmentSpatialPosition"],"0x010A":["US","1","ScreenMinimumGrayscaleBitDepth"],"0x010C":["US","1","ScreenMinimumColorBitDepth"],"0x010E":["US","1","ApplicationMaximumRepaintTime"],"0x0200":["SQ","1","DisplaySetsSequence"],"0x0202":["US","1","DisplaySetNumber"],"0x0203":["LO","1","DisplaySetLabel"],"0x0204":["US","1","DisplaySetPresentationGroup"],"0x0206":["LO","1","DisplaySetPresentationGroupDescription"],"0x0208":["CS","1","PartialDataDisplayHandling"],"0x0210":["SQ","1","SynchronizedScrollingSequence"],"0x0212":["US","2-n","DisplaySetScrollingGroup"],"0x0214":["SQ","1","NavigationIndicatorSequence"],"0x0216":["US","1","NavigationDisplaySet"],"0x0218":["US","1-n","ReferenceDisplaySets"],"0x0300":["SQ","1","ImageBoxesSequence"],"0x0302":["US","1","ImageBoxNumber"],"0x0304":["CS","1","ImageBoxLayoutType"],"0x0306":["US","1","ImageBoxTileHorizontalDimension"],"0x0308":["US","1","ImageBoxTileVerticalDimension"],"0x0310":["CS","1","ImageBoxScrollDirection"],"0x0312":["CS","1","ImageBoxSmallScrollType"],"0x0314":["US","1","ImageBoxSmallScrollAmount"],"0x0316":["CS","1","ImageBoxLargeScrollType"],"0x0318":["US","1","ImageBoxLargeScrollAmount"],"0x0320":["US","1","ImageBoxOverlapPriority"],"0x0330":["FD","1","CineRelativeToRealTime"],"0x0400":["SQ","1","FilterOperationsSequence"],"0x0402":["CS","1","FilterByCategory"],"0x0404":["CS","1","FilterByAttributePresence"],"0x0406":["CS","1","FilterByOperator"],"0x0420":["US","3","StructuredDisplayBackgroundCIELabValue"],"0x0421":["US","3","EmptyImageBoxCIELabValue"],"0x0422":["SQ","1","StructuredDisplayImageBoxSequence"],"0x0424":["SQ","1","StructuredDisplayTextBoxSequence"],"0x0427":["SQ","1","ReferencedFirstFrameSequence"],"0x0430":["SQ","1","ImageBoxSynchronizationSequence"],"0x0432":["US","2-n","SynchronizedImageBoxList"],"0x0434":["CS","1","TypeOfSynchronization"],"0x0500":["CS","1","BlendingOperationType"],"0x0510":["CS","1","ReformattingOperationType"],"0x0512":["FD","1","ReformattingThickness"],"0x0514":["FD","1","ReformattingInterval"],"0x0516":["CS","1","ReformattingOperationInitialViewDirection"],"0x0520":["CS","1-n","ThreeDRenderingType"],"0x0600":["SQ","1","SortingOperationsSequence"],"0x0602":["CS","1","SortByCategory"],"0x0604":["CS","1","SortingDirection"],"0x0700":["CS","2","DisplaySetPatientOrientation"],"0x0702":["CS","1","VOIType"],"0x0704":["CS","1","PseudoColorType"],"0x0705":["SQ","1","PseudoColorPaletteInstanceReferenceSequence"],"0x0706":["CS","1","ShowGrayscaleInverted"],"0x0710":["CS","1","ShowImageTrueSizeFlag"],"0x0712":["CS","1","ShowGraphicAnnotationFlag"],"0x0714":["CS","1","ShowPatientDemographicsFlag"],"0x0716":["CS","1","ShowAcquisitionTechniquesFlag"],"0x0717":["CS","1","DisplaySetHorizontalJustification"],"0x0718":["CS","1","DisplaySetVerticalJustification"]},"0x0074":{"0x0000":["UL","1","GenericGroupLength"],"0x0120":["FD","1","ContinuationStartMeterset"],"0x0121":["FD","1","ContinuationEndMeterset"],"0x1000":["CS","1","ProcedureStepState"],"0x1002":["SQ","1","ProcedureStepProgressInformationSequence"],"0x1004":["DS","1","ProcedureStepProgress"],"0x1006":["ST","1","ProcedureStepProgressDescription"],"0x1007":["SQ","1","ProcedureStepProgressParametersSequence"],"0x1008":["SQ","1","ProcedureStepCommunicationsURISequence"],"0x100A":["UR","1","ContactURI"],"0x100C":["LO","1","ContactDisplayName"],"0x100E":["SQ","1","ProcedureStepDiscontinuationReasonCodeSequence"],"0x1020":["SQ","1","BeamTaskSequence"],"0x1022":["CS","1","BeamTaskType"],"0x1024":["IS","1","BeamOrderIndexTrial"],"0x1025":["CS","1","AutosequenceFlag"],"0x1026":["FD","1","TableTopVerticalAdjustedPosition"],"0x1027":["FD","1","TableTopLongitudinalAdjustedPosition"],"0x1028":["FD","1","TableTopLateralAdjustedPosition"],"0x102A":["FD","1","PatientSupportAdjustedAngle"],"0x102B":["FD","1","TableTopEccentricAdjustedAngle"],"0x102C":["FD","1","TableTopPitchAdjustedAngle"],"0x102D":["FD","1","TableTopRollAdjustedAngle"],"0x1030":["SQ","1","DeliveryVerificationImageSequence"],"0x1032":["CS","1","VerificationImageTiming"],"0x1034":["CS","1","DoubleExposureFlag"],"0x1036":["CS","1","DoubleExposureOrdering"],"0x1038":["DS","1","DoubleExposureMetersetTrial"],"0x103A":["DS","4","DoubleExposureFieldDeltaTrial"],"0x1040":["SQ","1","RelatedReferenceRTImageSequence"],"0x1042":["SQ","1","GeneralMachineVerificationSequence"],"0x1044":["SQ","1","ConventionalMachineVerificationSequence"],"0x1046":["SQ","1","IonMachineVerificationSequence"],"0x1048":["SQ","1","FailedAttributesSequence"],"0x104A":["SQ","1","OverriddenAttributesSequence"],"0x104C":["SQ","1","ConventionalControlPointVerificationSequence"],"0x104E":["SQ","1","IonControlPointVerificationSequence"],"0x1050":["SQ","1","AttributeOccurrenceSequence"],"0x1052":["AT","1","AttributeOccurrencePointer"],"0x1054":["UL","1","AttributeItemSelector"],"0x1056":["LO","1","AttributeOccurrencePrivateCreator"],"0x1057":["IS","1-n","SelectorSequencePointerItems"],"0x1200":["CS","1","ScheduledProcedureStepPriority"],"0x1202":["LO","1","WorklistLabel"],"0x1204":["LO","1","ProcedureStepLabel"],"0x1210":["SQ","1","ScheduledProcessingParametersSequence"],"0x1212":["SQ","1","PerformedProcessingParametersSequence"],"0x1216":["SQ","1","UnifiedProcedureStepPerformedProcedureSequence"],"0x1220":["SQ","1","RelatedProcedureStepSequence"],"0x1222":["LO","1","ProcedureStepRelationshipType"],"0x1224":["SQ","1","ReplacedProcedureStepSequence"],"0x1230":["LO","1","DeletionLock"],"0x1234":["AE","1","ReceivingAE"],"0x1236":["AE","1","RequestingAE"],"0x1238":["LT","1","ReasonForCancellation"],"0x1242":["CS","1","SCPStatus"],"0x1244":["CS","1","SubscriptionListStatus"],"0x1246":["CS","1","UnifiedProcedureStepListStatus"],"0x1324":["UL","1","BeamOrderIndex"],"0x1338":["FD","1","DoubleExposureMeterset"],"0x133A":["FD","4","DoubleExposureFieldDelta"],"0x1401":["SQ","1","BrachyTaskSequence"],"0x1402":["DS","1","ContinuationStartTotalReferenceAirKerma"],"0x1403":["DS","1","ContinuationEndTotalReferenceAirKerma"],"0x1404":["IS","1","ContinuationPulseNumber"],"0x1405":["SQ","1","ChannelDeliveryOrderSequence"],"0x1406":["IS","1","ReferencedChannelNumber"],"0x1407":["DS","1","StartCumulativeTimeWeight"],"0x1408":["DS","1","EndCumulativeTimeWeight"],"0x1409":["SQ","1","OmittedChannelSequence"],"0x140A":["CS","1","ReasonForChannelOmission"],"0x140B":["LO","1","ReasonForChannelOmissionDescription"],"0x140C":["IS","1","ChannelDeliveryOrderIndex"],"0x140D":["SQ","1","ChannelDeliveryContinuationSequence"],"0x140E":["SQ","1","OmittedApplicationSetupSequence"]},"0x0076":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["LO","1","ImplantAssemblyTemplateName"],"0x0003":["LO","1","ImplantAssemblyTemplateIssuer"],"0x0006":["LO","1","ImplantAssemblyTemplateVersion"],"0x0008":["SQ","1","ReplacedImplantAssemblyTemplateSequence"],"0x000A":["CS","1","ImplantAssemblyTemplateType"],"0x000C":["SQ","1","OriginalImplantAssemblyTemplateSequence"],"0x000E":["SQ","1","DerivationImplantAssemblyTemplateSequence"],"0x0010":["SQ","1","ImplantAssemblyTemplateTargetAnatomySequence"],"0x0020":["SQ","1","ProcedureTypeCodeSequence"],"0x0030":["LO","1","SurgicalTechnique"],"0x0032":["SQ","1","ComponentTypesSequence"],"0x0034":["SQ","1","ComponentTypeCodeSequence"],"0x0036":["CS","1","ExclusiveComponentType"],"0x0038":["CS","1","MandatoryComponentType"],"0x0040":["SQ","1","ComponentSequence"],"0x0055":["US","1","ComponentID"],"0x0060":["SQ","1","ComponentAssemblySequence"],"0x0070":["US","1","Component1ReferencedID"],"0x0080":["US","1","Component1ReferencedMatingFeatureSetID"],"0x0090":["US","1","Component1ReferencedMatingFeatureID"],"0x00A0":["US","1","Component2ReferencedID"],"0x00B0":["US","1","Component2ReferencedMatingFeatureSetID"],"0x00C0":["US","1","Component2ReferencedMatingFeatureID"]},"0x0078":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["LO","1","ImplantTemplateGroupName"],"0x0010":["ST","1","ImplantTemplateGroupDescription"],"0x0020":["LO","1","ImplantTemplateGroupIssuer"],"0x0024":["LO","1","ImplantTemplateGroupVersion"],"0x0026":["SQ","1","ReplacedImplantTemplateGroupSequence"],"0x0028":["SQ","1","ImplantTemplateGroupTargetAnatomySequence"],"0x002A":["SQ","1","ImplantTemplateGroupMembersSequence"],"0x002E":["US","1","ImplantTemplateGroupMemberID"],"0x0050":["FD","3","ThreeDImplantTemplateGroupMemberMatchingPoint"],"0x0060":["FD","9","ThreeDImplantTemplateGroupMemberMatchingAxes"],"0x0070":["SQ","1","ImplantTemplateGroupMemberMatching2DCoordinatesSequence"],"0x0090":["FD","2","TwoDImplantTemplateGroupMemberMatchingPoint"],"0x00A0":["FD","4","TwoDImplantTemplateGroupMemberMatchingAxes"],"0x00B0":["SQ","1","ImplantTemplateGroupVariationDimensionSequence"],"0x00B2":["LO","1","ImplantTemplateGroupVariationDimensionName"],"0x00B4":["SQ","1","ImplantTemplateGroupVariationDimensionRankSequence"],"0x00B6":["US","1","ReferencedImplantTemplateGroupMemberID"],"0x00B8":["US","1","ImplantTemplateGroupVariationDimensionRank"]},"0x0080":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["SQ","1","SurfaceScanAcquisitionTypeCodeSequence"],"0x0002":["SQ","1","SurfaceScanModeCodeSequence"],"0x0003":["SQ","1","RegistrationMethodCodeSequence"],"0x0004":["FD","1","ShotDurationTime"],"0x0005":["FD","1","ShotOffsetTime"],"0x0006":["US","1-n","SurfacePointPresentationValueData"],"0x0007":["US","3-3n","SurfacePointColorCIELabValueData"],"0x0008":["SQ","1","UVMappingSequence"],"0x0009":["SH","1","TextureLabel"],"0x0010":["OF","1","UValueData"],"0x0011":["OF","1","VValueData"],"0x0012":["SQ","1","ReferencedTextureSequence"],"0x0013":["SQ","1","ReferencedSurfaceDataSequence"]},"0x0082":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["CS","1","AssessmentSummary"],"0x0003":["UT","1","AssessmentSummaryDescription"],"0x0004":["SQ","1","AssessedSOPInstanceSequence"],"0x0005":["SQ","1","ReferencedComparisonSOPInstanceSequence"],"0x0006":["UL","1","NumberOfAssessmentObservations"],"0x0007":["SQ","1","AssessmentObservationsSequence"],"0x0008":["CS","1","ObservationSignificance"],"0x000A":["UT","1","ObservationDescription"],"0x000C":["SQ","1","StructuredConstraintObservationSequence"],"0x0010":["SQ","1","AssessedAttributeValueSequence"],"0x0016":["LO","1","AssessmentSetID"],"0x0017":["SQ","1","AssessmentRequesterSequence"],"0x0018":["LO","1","SelectorAttributeName"],"0x0019":["LO","1","SelectorAttributeKeyword"],"0x0021":["SQ","1","AssessmentTypeCodeSequence"],"0x0022":["SQ","1","ObservationBasisCodeSequence"],"0x0023":["LO","1","AssessmentLabel"],"0x0032":["CS","1","ConstraintType"],"0x0033":["UT","1","SpecificationSelectionGuidance"],"0x0034":["SQ","1","ConstraintValueSequence"],"0x0035":["SQ","1","RecommendedDefaultValueSequence"],"0x0036":["CS","1","ConstraintViolationSignificance"],"0x0037":["UT","1","ConstraintViolationCondition"],"0x0038":["CS","1","ModifiableConstraintFlag"]},"0x0088":{"0x0000":["UL","1","GenericGroupLength"],"0x0130":["SH","1","StorageMediaFileSetID"],"0x0140":["UI","1","StorageMediaFileSetUID"],"0x0200":["SQ","1","IconImageSequence"],"0x0904":["LO","1","TopicTitle"],"0x0906":["ST","1","TopicSubject"],"0x0910":["LO","1","TopicAuthor"],"0x0912":["LO","1-32","TopicKeywords"]},"0x0100":{"0x0000":["UL","1","GenericGroupLength"],"0x0410":["CS","1","SOPInstanceStatus"],"0x0420":["DT","1","SOPAuthorizationDateTime"],"0x0424":["LT","1","SOPAuthorizationComment"],"0x0426":["LO","1","AuthorizationEquipmentCertificationNumber"]},"0x0400":{"0x0000":["UL","1","GenericGroupLength"],"0x0005":["US","1","MACIDNumber"],"0x0010":["UI","1","MACCalculationTransferSyntaxUID"],"0x0015":["CS","1","MACAlgorithm"],"0x0020":["AT","1-n","DataElementsSigned"],"0x0100":["UI","1","DigitalSignatureUID"],"0x0105":["DT","1","DigitalSignatureDateTime"],"0x0110":["CS","1","CertificateType"],"0x0115":["OB","1","CertificateOfSigner"],"0x0120":["OB","1","Signature"],"0x0305":["CS","1","CertifiedTimestampType"],"0x0310":["OB","1","CertifiedTimestamp"],"0x0315":["FL","1",""],"0x0401":["SQ","1","DigitalSignaturePurposeCodeSequence"],"0x0402":["SQ","1","ReferencedDigitalSignatureSequence"],"0x0403":["SQ","1","ReferencedSOPInstanceMACSequence"],"0x0404":["OB","1","MAC"],"0x0500":["SQ","1","EncryptedAttributesSequence"],"0x0510":["UI","1","EncryptedContentTransferSyntaxUID"],"0x0520":["OB","1","EncryptedContent"],"0x0550":["SQ","1","ModifiedAttributesSequence"],"0x0551":["SQ","1","NonconformingModifiedAttributesSequence"],"0x0552":["OB","1","NonconformingDataElementValue"],"0x0561":["SQ","1","OriginalAttributesSequence"],"0x0562":["DT","1","AttributeModificationDateTime"],"0x0563":["LO","1","ModifyingSystem"],"0x0564":["LO","1","SourceOfPreviousValues"],"0x0565":["CS","1","ReasonForTheAttributeModification"],"0x0600":["CS","1","InstanceOriginStatus"]},"0x1000":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["US","3","EscapeTriplet"],"0x0011":["US","3","RunLengthTriplet"],"0x0012":["US","1","HuffmanTableSize"],"0x0013":["US","3","HuffmanTableTriplet"],"0x0014":["US","1","ShiftTableSize"],"0x0015":["US","3","ShiftTableTriplet"]},"0x1010":{"0x0000":["UL","1","GenericGroupLength"],"0x0004":["US","1-n","ZonalMap"]},"0x2000":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["IS","1","NumberOfCopies"],"0x001E":["SQ","1","PrinterConfigurationSequence"],"0x0020":["CS","1","PrintPriority"],"0x0030":["CS","1","MediumType"],"0x0040":["CS","1","FilmDestination"],"0x0050":["LO","1","FilmSessionLabel"],"0x0060":["IS","1","MemoryAllocation"],"0x0061":["IS","1","MaximumMemoryAllocation"],"0x0062":["CS","1","ColorImagePrintingFlag"],"0x0063":["CS","1","CollationFlag"],"0x0065":["CS","1","AnnotationFlag"],"0x0067":["CS","1","ImageOverlayFlag"],"0x0069":["CS","1","PresentationLUTFlag"],"0x006A":["CS","1","ImageBoxPresentationLUTFlag"],"0x00A0":["US","1","MemoryBitDepth"],"0x00A1":["US","1","PrintingBitDepth"],"0x00A2":["SQ","1","MediaInstalledSequence"],"0x00A4":["SQ","1","OtherMediaAvailableSequence"],"0x00A8":["SQ","1","SupportedImageDisplayFormatsSequence"],"0x0500":["SQ","1","ReferencedFilmBoxSequence"],"0x0510":["SQ","1","ReferencedStoredPrintSequence"]},"0x2010":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["ST","1","ImageDisplayFormat"],"0x0030":["CS","1","AnnotationDisplayFormatID"],"0x0040":["CS","1","FilmOrientation"],"0x0050":["CS","1","FilmSizeID"],"0x0052":["CS","1","PrinterResolutionID"],"0x0054":["CS","1","DefaultPrinterResolutionID"],"0x0060":["CS","1","MagnificationType"],"0x0080":["CS","1","SmoothingType"],"0x00A6":["CS","1","DefaultMagnificationType"],"0x00A7":["CS","1-n","OtherMagnificationTypesAvailable"],"0x00A8":["CS","1","DefaultSmoothingType"],"0x00A9":["CS","1-n","OtherSmoothingTypesAvailable"],"0x0100":["CS","1","BorderDensity"],"0x0110":["CS","1","EmptyImageDensity"],"0x0120":["US","1","MinDensity"],"0x0130":["US","1","MaxDensity"],"0x0140":["CS","1","Trim"],"0x0150":["ST","1","ConfigurationInformation"],"0x0152":["LT","1","ConfigurationInformationDescription"],"0x0154":["IS","1","MaximumCollatedFilms"],"0x015E":["US","1","Illumination"],"0x0160":["US","1","ReflectedAmbientLight"],"0x0376":["DS","2","PrinterPixelSpacing"],"0x0500":["SQ","1","ReferencedFilmSessionSequence"],"0x0510":["SQ","1","ReferencedImageBoxSequence"],"0x0520":["SQ","1","ReferencedBasicAnnotationBoxSequence"]},"0x2020":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["US","1","ImageBoxPosition"],"0x0020":["CS","1","Polarity"],"0x0030":["DS","1","RequestedImageSize"],"0x0040":["CS","1","RequestedDecimateCropBehavior"],"0x0050":["CS","1","RequestedResolutionID"],"0x00A0":["CS","1","RequestedImageSizeFlag"],"0x00A2":["CS","1","DecimateCropResult"],"0x0110":["SQ","1","BasicGrayscaleImageSequence"],"0x0111":["SQ","1","BasicColorImageSequence"],"0x0130":["SQ","1","ReferencedImageOverlayBoxSequence"],"0x0140":["SQ","1","ReferencedVOILUTBoxSequence"]},"0x2030":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["US","1","AnnotationPosition"],"0x0020":["LO","1","TextString"]},"0x2040":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["SQ","1","ReferencedOverlayPlaneSequence"],"0x0011":["US","1-99","ReferencedOverlayPlaneGroups"],"0x0020":["SQ","1","OverlayPixelDataSequence"],"0x0060":["CS","1","OverlayMagnificationType"],"0x0070":["CS","1","OverlaySmoothingType"],"0x0072":["CS","1","OverlayOrImageMagnification"],"0x0074":["US","1","MagnifyToNumberOfColumns"],"0x0080":["CS","1","OverlayForegroundDensity"],"0x0082":["CS","1","OverlayBackgroundDensity"],"0x0090":["CS","1","OverlayMode"],"0x0100":["CS","1","ThresholdDensity"],"0x0500":["SQ","1","ReferencedImageBoxSequenceRetired"]},"0x2050":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["SQ","1","PresentationLUTSequence"],"0x0020":["CS","1","PresentationLUTShape"],"0x0500":["SQ","1","ReferencedPresentationLUTSequence"]},"0x2100":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["SH","1","PrintJobID"],"0x0020":["CS","1","ExecutionStatus"],"0x0030":["CS","1","ExecutionStatusInfo"],"0x0040":["DA","1","CreationDate"],"0x0050":["TM","1","CreationTime"],"0x0070":["AE","1","Originator"],"0x0140":["AE","1","DestinationAE"],"0x0160":["SH","1","OwnerID"],"0x0170":["IS","1","NumberOfFilms"],"0x0500":["SQ","1","ReferencedPrintJobSequencePullStoredPrint"]},"0x2110":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["CS","1","PrinterStatus"],"0x0020":["CS","1","PrinterStatusInfo"],"0x0030":["LO","1","PrinterName"],"0x0099":["SH","1","PrintQueueID"]},"0x2120":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["CS","1","QueueStatus"],"0x0050":["SQ","1","PrintJobDescriptionSequence"],"0x0070":["SQ","1","ReferencedPrintJobSequence"]},"0x2130":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["SQ","1","PrintManagementCapabilitiesSequence"],"0x0015":["SQ","1","PrinterCharacteristicsSequence"],"0x0030":["SQ","1","FilmBoxContentSequence"],"0x0040":["SQ","1","ImageBoxContentSequence"],"0x0050":["SQ","1","AnnotationContentSequence"],"0x0060":["SQ","1","ImageOverlayBoxContentSequence"],"0x0080":["SQ","1","PresentationLUTContentSequence"],"0x00A0":["SQ","1","ProposedStudySequence"],"0x00C0":["SQ","1","OriginalImageSequence"]},"0x2200":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["CS","1","LabelUsingInformationExtractedFromInstances"],"0x0002":["UT","1","LabelText"],"0x0003":["CS","1","LabelStyleSelection"],"0x0004":["LT","1","MediaDisposition"],"0x0005":["LT","1","BarcodeValue"],"0x0006":["CS","1","BarcodeSymbology"],"0x0007":["CS","1","AllowMediaSplitting"],"0x0008":["CS","1","IncludeNonDICOMObjects"],"0x0009":["CS","1","IncludeDisplayApplication"],"0x000A":["CS","1","PreserveCompositeInstancesAfterMediaCreation"],"0x000B":["US","1","TotalNumberOfPiecesOfMediaCreated"],"0x000C":["LO","1","RequestedMediaApplicationProfile"],"0x000D":["SQ","1","ReferencedStorageMediaSequence"],"0x000E":["AT","1-n","FailureAttributes"],"0x000F":["CS","1","AllowLossyCompression"],"0x0020":["CS","1","RequestPriority"]},"0x3002":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["SH","1","RTImageLabel"],"0x0003":["LO","1","RTImageName"],"0x0004":["ST","1","RTImageDescription"],"0x000A":["CS","1","ReportedValuesOrigin"],"0x000C":["CS","1","RTImagePlane"],"0x000D":["DS","3","XRayImageReceptorTranslation"],"0x000E":["DS","1","XRayImageReceptorAngle"],"0x0010":["DS","6","RTImageOrientation"],"0x0011":["DS","2","ImagePlanePixelSpacing"],"0x0012":["DS","2","RTImagePosition"],"0x0020":["SH","1","RadiationMachineName"],"0x0022":["DS","1","RadiationMachineSAD"],"0x0024":["DS","1","RadiationMachineSSD"],"0x0026":["DS","1","RTImageSID"],"0x0028":["DS","1","SourceToReferenceObjectDistance"],"0x0029":["IS","1","FractionNumber"],"0x0030":["SQ","1","ExposureSequence"],"0x0032":["DS","1","MetersetExposure"],"0x0034":["DS","4","DiaphragmPosition"],"0x0040":["SQ","1","FluenceMapSequence"],"0x0041":["CS","1","FluenceDataSource"],"0x0042":["DS","1","FluenceDataScale"],"0x0050":["SQ","1","PrimaryFluenceModeSequence"],"0x0051":["CS","1","FluenceMode"],"0x0052":["SH","1","FluenceModeID"]},"0x3004":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["CS","1","DVHType"],"0x0002":["CS","1","DoseUnits"],"0x0004":["CS","1","DoseType"],"0x0005":["CS","1","SpatialTransformOfDose"],"0x0006":["LO","1","DoseComment"],"0x0008":["DS","3","NormalizationPoint"],"0x000A":["CS","1","DoseSummationType"],"0x000C":["DS","2-n","GridFrameOffsetVector"],"0x000E":["DS","1","DoseGridScaling"],"0x0010":["SQ","1","RTDoseROISequence"],"0x0012":["DS","1","DoseValue"],"0x0014":["CS","1-3","TissueHeterogeneityCorrection"],"0x0040":["DS","3","DVHNormalizationPoint"],"0x0042":["DS","1","DVHNormalizationDoseValue"],"0x0050":["SQ","1","DVHSequence"],"0x0052":["DS","1","DVHDoseScaling"],"0x0054":["CS","1","DVHVolumeUnits"],"0x0056":["IS","1","DVHNumberOfBins"],"0x0058":["DS","2-2n","DVHData"],"0x0060":["SQ","1","DVHReferencedROISequence"],"0x0062":["CS","1","DVHROIContributionType"],"0x0070":["DS","1","DVHMinimumDose"],"0x0072":["DS","1","DVHMaximumDose"],"0x0074":["DS","1","DVHMeanDose"]},"0x3006":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["SH","1","StructureSetLabel"],"0x0004":["LO","1","StructureSetName"],"0x0006":["ST","1","StructureSetDescription"],"0x0008":["DA","1","StructureSetDate"],"0x0009":["TM","1","StructureSetTime"],"0x0010":["SQ","1","ReferencedFrameOfReferenceSequence"],"0x0012":["SQ","1","RTReferencedStudySequence"],"0x0014":["SQ","1","RTReferencedSeriesSequence"],"0x0016":["SQ","1","ContourImageSequence"],"0x0018":["SQ","1","PredecessorStructureSetSequence"],"0x0020":["SQ","1","StructureSetROISequence"],"0x0022":["IS","1","ROINumber"],"0x0024":["UI","1","ReferencedFrameOfReferenceUID"],"0x0026":["LO","1","ROIName"],"0x0028":["ST","1","ROIDescription"],"0x002A":["IS","3","ROIDisplayColor"],"0x002C":["DS","1","ROIVolume"],"0x0030":["SQ","1","RTRelatedROISequence"],"0x0033":["CS","1","RTROIRelationship"],"0x0036":["CS","1","ROIGenerationAlgorithm"],"0x0037":["SQ","1","ROIDerivationAlgorithmIdentificationSequence"],"0x0038":["LO","1","ROIGenerationDescription"],"0x0039":["SQ","1","ROIContourSequence"],"0x0040":["SQ","1","ContourSequence"],"0x0042":["CS","1","ContourGeometricType"],"0x0044":["DS","1","ContourSlabThickness"],"0x0045":["DS","3","ContourOffsetVector"],"0x0046":["IS","1","NumberOfContourPoints"],"0x0048":["IS","1","ContourNumber"],"0x0049":["IS","1-n","AttachedContours"],"0x004A":["SQ","1","SourcePixelPlanesCharacteristicsSequence"],"0x0050":["DS","3-3n","ContourData"],"0x0080":["SQ","1","RTROIObservationsSequence"],"0x0082":["IS","1","ObservationNumber"],"0x0084":["IS","1","ReferencedROINumber"],"0x0085":["SH","1","ROIObservationLabel"],"0x0086":["SQ","1","RTROIIdentificationCodeSequence"],"0x0088":["ST","1","ROIObservationDescription"],"0x00A0":["SQ","1","RelatedRTROIObservationsSequence"],"0x00A4":["CS","1","RTROIInterpretedType"],"0x00A6":["PN","1","ROIInterpreter"],"0x00B0":["SQ","1","ROIPhysicalPropertiesSequence"],"0x00B2":["CS","1","ROIPhysicalProperty"],"0x00B4":["DS","1","ROIPhysicalPropertyValue"],"0x00B6":["SQ","1","ROIElementalCompositionSequence"],"0x00B7":["US","1","ROIElementalCompositionAtomicNumber"],"0x00B8":["FL","1","ROIElementalCompositionAtomicMassFraction"],"0x00B9":["SQ","1","AdditionalRTROIIdentificationCodeSequence"],"0x00C0":["SQ","1","FrameOfReferenceRelationshipSequence"],"0x00C2":["UI","1","RelatedFrameOfReferenceUID"],"0x00C4":["CS","1","FrameOfReferenceTransformationType"],"0x00C6":["DS","16","FrameOfReferenceTransformationMatrix"],"0x00C8":["LO","1","FrameOfReferenceTransformationComment"],"0x00C9":["SQ","1","PatientLocationCoordinatesSequence"],"0x00CA":["SQ","1","PatientLocationCoordinatesCodeSequence"],"0x00CB":["SQ","1","PatientSupportPositionSequence"]},"0x3008":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["SQ","1","MeasuredDoseReferenceSequence"],"0x0012":["ST","1","MeasuredDoseDescription"],"0x0014":["CS","1","MeasuredDoseType"],"0x0016":["DS","1","MeasuredDoseValue"],"0x0020":["SQ","1","TreatmentSessionBeamSequence"],"0x0021":["SQ","1","TreatmentSessionIonBeamSequence"],"0x0022":["IS","1","CurrentFractionNumber"],"0x0024":["DA","1","TreatmentControlPointDate"],"0x0025":["TM","1","TreatmentControlPointTime"],"0x002A":["CS","1","TreatmentTerminationStatus"],"0x002B":["SH","1","TreatmentTerminationCode"],"0x002C":["CS","1","TreatmentVerificationStatus"],"0x0030":["SQ","1","ReferencedTreatmentRecordSequence"],"0x0032":["DS","1","SpecifiedPrimaryMeterset"],"0x0033":["DS","1","SpecifiedSecondaryMeterset"],"0x0036":["DS","1","DeliveredPrimaryMeterset"],"0x0037":["DS","1","DeliveredSecondaryMeterset"],"0x003A":["DS","1","SpecifiedTreatmentTime"],"0x003B":["DS","1","DeliveredTreatmentTime"],"0x0040":["SQ","1","ControlPointDeliverySequence"],"0x0041":["SQ","1","IonControlPointDeliverySequence"],"0x0042":["DS","1","SpecifiedMeterset"],"0x0044":["DS","1","DeliveredMeterset"],"0x0045":["FL","1","MetersetRateSet"],"0x0046":["FL","1","MetersetRateDelivered"],"0x0047":["FL","1-n","ScanSpotMetersetsDelivered"],"0x0048":["DS","1","DoseRateDelivered"],"0x0050":["SQ","1","TreatmentSummaryCalculatedDoseReferenceSequence"],"0x0052":["DS","1","CumulativeDoseToDoseReference"],"0x0054":["DA","1","FirstTreatmentDate"],"0x0056":["DA","1","MostRecentTreatmentDate"],"0x005A":["IS","1","NumberOfFractionsDelivered"],"0x0060":["SQ","1","OverrideSequence"],"0x0061":["AT","1","ParameterSequencePointer"],"0x0062":["AT","1","OverrideParameterPointer"],"0x0063":["IS","1","ParameterItemIndex"],"0x0064":["IS","1","MeasuredDoseReferenceNumber"],"0x0065":["AT","1","ParameterPointer"],"0x0066":["ST","1","OverrideReason"],"0x0067":["US","1","ParameterValueNumber"],"0x0068":["SQ","1","CorrectedParameterSequence"],"0x006A":["FL","1","CorrectionValue"],"0x0070":["SQ","1","CalculatedDoseReferenceSequence"],"0x0072":["IS","1","CalculatedDoseReferenceNumber"],"0x0074":["ST","1","CalculatedDoseReferenceDescription"],"0x0076":["DS","1","CalculatedDoseReferenceDoseValue"],"0x0078":["DS","1","StartMeterset"],"0x007A":["DS","1","EndMeterset"],"0x0080":["SQ","1","ReferencedMeasuredDoseReferenceSequence"],"0x0082":["IS","1","ReferencedMeasuredDoseReferenceNumber"],"0x0090":["SQ","1","ReferencedCalculatedDoseReferenceSequence"],"0x0092":["IS","1","ReferencedCalculatedDoseReferenceNumber"],"0x00A0":["SQ","1","BeamLimitingDeviceLeafPairsSequence"],"0x00B0":["SQ","1","RecordedWedgeSequence"],"0x00C0":["SQ","1","RecordedCompensatorSequence"],"0x00D0":["SQ","1","RecordedBlockSequence"],"0x00D1":["SQ","1","RecordedBlockSlabSequence"],"0x00E0":["SQ","1","TreatmentSummaryMeasuredDoseReferenceSequence"],"0x00F0":["SQ","1","RecordedSnoutSequence"],"0x00F2":["SQ","1","RecordedRangeShifterSequence"],"0x00F4":["SQ","1","RecordedLateralSpreadingDeviceSequence"],"0x00F6":["SQ","1","RecordedRangeModulatorSequence"],"0x0100":["SQ","1","RecordedSourceSequence"],"0x0105":["LO","1","SourceSerialNumber"],"0x0110":["SQ","1","TreatmentSessionApplicationSetupSequence"],"0x0116":["CS","1","ApplicationSetupCheck"],"0x0120":["SQ","1","RecordedBrachyAccessoryDeviceSequence"],"0x0122":["IS","1","ReferencedBrachyAccessoryDeviceNumber"],"0x0130":["SQ","1","RecordedChannelSequence"],"0x0132":["DS","1","SpecifiedChannelTotalTime"],"0x0134":["DS","1","DeliveredChannelTotalTime"],"0x0136":["IS","1","SpecifiedNumberOfPulses"],"0x0138":["IS","1","DeliveredNumberOfPulses"],"0x013A":["DS","1","SpecifiedPulseRepetitionInterval"],"0x013C":["DS","1","DeliveredPulseRepetitionInterval"],"0x0140":["SQ","1","RecordedSourceApplicatorSequence"],"0x0142":["IS","1","ReferencedSourceApplicatorNumber"],"0x0150":["SQ","1","RecordedChannelShieldSequence"],"0x0152":["IS","1","ReferencedChannelShieldNumber"],"0x0160":["SQ","1","BrachyControlPointDeliveredSequence"],"0x0162":["DA","1","SafePositionExitDate"],"0x0164":["TM","1","SafePositionExitTime"],"0x0166":["DA","1","SafePositionReturnDate"],"0x0168":["TM","1","SafePositionReturnTime"],"0x0171":["SQ","1","PulseSpecificBrachyControlPointDeliveredSequence"],"0x0172":["US","1","PulseNumber"],"0x0173":["SQ","1","BrachyPulseControlPointDeliveredSequence"],"0x0200":["CS","1","CurrentTreatmentStatus"],"0x0202":["ST","1","TreatmentStatusComment"],"0x0220":["SQ","1","FractionGroupSummarySequence"],"0x0223":["IS","1","ReferencedFractionNumber"],"0x0224":["CS","1","FractionGroupType"],"0x0230":["CS","1","BeamStopperPosition"],"0x0240":["SQ","1","FractionStatusSummarySequence"],"0x0250":["DA","1","TreatmentDate"],"0x0251":["TM","1","TreatmentTime"]},"0x300A":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["SH","1","RTPlanLabel"],"0x0003":["LO","1","RTPlanName"],"0x0004":["ST","1","RTPlanDescription"],"0x0006":["DA","1","RTPlanDate"],"0x0007":["TM","1","RTPlanTime"],"0x0009":["LO","1-n","TreatmentProtocols"],"0x000A":["CS","1","PlanIntent"],"0x000B":["LO","1-n","TreatmentSites"],"0x000C":["CS","1","RTPlanGeometry"],"0x000E":["ST","1","PrescriptionDescription"],"0x0010":["SQ","1","DoseReferenceSequence"],"0x0012":["IS","1","DoseReferenceNumber"],"0x0013":["UI","1","DoseReferenceUID"],"0x0014":["CS","1","DoseReferenceStructureType"],"0x0015":["CS","1","NominalBeamEnergyUnit"],"0x0016":["LO","1","DoseReferenceDescription"],"0x0018":["DS","3","DoseReferencePointCoordinates"],"0x001A":["DS","1","NominalPriorDose"],"0x0020":["CS","1","DoseReferenceType"],"0x0021":["DS","1","ConstraintWeight"],"0x0022":["DS","1","DeliveryWarningDose"],"0x0023":["DS","1","DeliveryMaximumDose"],"0x0025":["DS","1","TargetMinimumDose"],"0x0026":["DS","1","TargetPrescriptionDose"],"0x0027":["DS","1","TargetMaximumDose"],"0x0028":["DS","1","TargetUnderdoseVolumeFraction"],"0x002A":["DS","1","OrganAtRiskFullVolumeDose"],"0x002B":["DS","1","OrganAtRiskLimitDose"],"0x002C":["DS","1","OrganAtRiskMaximumDose"],"0x002D":["DS","1","OrganAtRiskOverdoseVolumeFraction"],"0x0040":["SQ","1","ToleranceTableSequence"],"0x0042":["IS","1","ToleranceTableNumber"],"0x0043":["SH","1","ToleranceTableLabel"],"0x0044":["DS","1","GantryAngleTolerance"],"0x0046":["DS","1","BeamLimitingDeviceAngleTolerance"],"0x0048":["SQ","1","BeamLimitingDeviceToleranceSequence"],"0x004A":["DS","1","BeamLimitingDevicePositionTolerance"],"0x004B":["FL","1","SnoutPositionTolerance"],"0x004C":["DS","1","PatientSupportAngleTolerance"],"0x004E":["DS","1","TableTopEccentricAngleTolerance"],"0x004F":["FL","1","TableTopPitchAngleTolerance"],"0x0050":["FL","1","TableTopRollAngleTolerance"],"0x0051":["DS","1","TableTopVerticalPositionTolerance"],"0x0052":["DS","1","TableTopLongitudinalPositionTolerance"],"0x0053":["DS","1","TableTopLateralPositionTolerance"],"0x0055":["CS","1","RTPlanRelationship"],"0x0070":["SQ","1","FractionGroupSequence"],"0x0071":["IS","1","FractionGroupNumber"],"0x0072":["LO","1","FractionGroupDescription"],"0x0078":["IS","1","NumberOfFractionsPlanned"],"0x0079":["IS","1","NumberOfFractionPatternDigitsPerDay"],"0x007A":["IS","1","RepeatFractionCycleLength"],"0x007B":["LT","1","FractionPattern"],"0x0080":["IS","1","NumberOfBeams"],"0x0082":["DS","3","BeamDoseSpecificationPoint"],"0x0083":["UI","1","ReferencedDoseReferenceUID"],"0x0084":["DS","1","BeamDose"],"0x0086":["DS","1","BeamMeterset"],"0x0088":["FL","1","BeamDosePointDepth"],"0x0089":["FL","1","BeamDosePointEquivalentDepth"],"0x008A":["FL","1","BeamDosePointSSD"],"0x008B":["CS","1","BeamDoseMeaning"],"0x008C":["SQ","1","BeamDoseVerificationControlPointSequence"],"0x008D":["FL","1","AverageBeamDosePointDepth"],"0x008E":["FL","1","AverageBeamDosePointEquivalentDepth"],"0x008F":["FL","1","AverageBeamDosePointSSD"],"0x0090":["CS","1","BeamDoseType"],"0x0091":["DS","1","AlternateBeamDose"],"0x0092":["CS","1","AlternateBeamDoseType"],"0x0093":["CS","1","DepthValueAveragingFlag"],"0x0094":["DS","1","BeamDosePointSourceToExternalContourDistance"],"0x00A0":["IS","1","NumberOfBrachyApplicationSetups"],"0x00A2":["DS","3","BrachyApplicationSetupDoseSpecificationPoint"],"0x00A4":["DS","1","BrachyApplicationSetupDose"],"0x00B0":["SQ","1","BeamSequence"],"0x00B2":["SH","1","TreatmentMachineName"],"0x00B3":["CS","1","PrimaryDosimeterUnit"],"0x00B4":["DS","1","SourceAxisDistance"],"0x00B6":["SQ","1","BeamLimitingDeviceSequence"],"0x00B8":["CS","1","RTBeamLimitingDeviceType"],"0x00BA":["DS","1","SourceToBeamLimitingDeviceDistance"],"0x00BB":["FL","1","IsocenterToBeamLimitingDeviceDistance"],"0x00BC":["IS","1","NumberOfLeafJawPairs"],"0x00BE":["DS","3-n","LeafPositionBoundaries"],"0x00C0":["IS","1","BeamNumber"],"0x00C2":["LO","1","BeamName"],"0x00C3":["ST","1","BeamDescription"],"0x00C4":["CS","1","BeamType"],"0x00C5":["FD","1","BeamDeliveryDurationLimit"],"0x00C6":["CS","1","RadiationType"],"0x00C7":["CS","1","HighDoseTechniqueType"],"0x00C8":["IS","1","ReferenceImageNumber"],"0x00CA":["SQ","1","PlannedVerificationImageSequence"],"0x00CC":["LO","1-n","ImagingDeviceSpecificAcquisitionParameters"],"0x00CE":["CS","1","TreatmentDeliveryType"],"0x00D0":["IS","1","NumberOfWedges"],"0x00D1":["SQ","1","WedgeSequence"],"0x00D2":["IS","1","WedgeNumber"],"0x00D3":["CS","1","WedgeType"],"0x00D4":["SH","1","WedgeID"],"0x00D5":["IS","1","WedgeAngle"],"0x00D6":["DS","1","WedgeFactor"],"0x00D7":["FL","1","TotalWedgeTrayWaterEquivalentThickness"],"0x00D8":["DS","1","WedgeOrientation"],"0x00D9":["FL","1","IsocenterToWedgeTrayDistance"],"0x00DA":["DS","1","SourceToWedgeTrayDistance"],"0x00DB":["FL","1","WedgeThinEdgePosition"],"0x00DC":["SH","1","BolusID"],"0x00DD":["ST","1","BolusDescription"],"0x00DE":["DS","1","EffectiveWedgeAngle"],"0x00E0":["IS","1","NumberOfCompensators"],"0x00E1":["SH","1","MaterialID"],"0x00E2":["DS","1","TotalCompensatorTrayFactor"],"0x00E3":["SQ","1","CompensatorSequence"],"0x00E4":["IS","1","CompensatorNumber"],"0x00E5":["SH","1","CompensatorID"],"0x00E6":["DS","1","SourceToCompensatorTrayDistance"],"0x00E7":["IS","1","CompensatorRows"],"0x00E8":["IS","1","CompensatorColumns"],"0x00E9":["DS","2","CompensatorPixelSpacing"],"0x00EA":["DS","2","CompensatorPosition"],"0x00EB":["DS","1-n","CompensatorTransmissionData"],"0x00EC":["DS","1-n","CompensatorThicknessData"],"0x00ED":["IS","1","NumberOfBoli"],"0x00EE":["CS","1","CompensatorType"],"0x00EF":["SH","1","CompensatorTrayID"],"0x00F0":["IS","1","NumberOfBlocks"],"0x00F2":["DS","1","TotalBlockTrayFactor"],"0x00F3":["FL","1","TotalBlockTrayWaterEquivalentThickness"],"0x00F4":["SQ","1","BlockSequence"],"0x00F5":["SH","1","BlockTrayID"],"0x00F6":["DS","1","SourceToBlockTrayDistance"],"0x00F7":["FL","1","IsocenterToBlockTrayDistance"],"0x00F8":["CS","1","BlockType"],"0x00F9":["LO","1","AccessoryCode"],"0x00FA":["CS","1","BlockDivergence"],"0x00FB":["CS","1","BlockMountingPosition"],"0x00FC":["IS","1","BlockNumber"],"0x00FE":["LO","1","BlockName"],"0x0100":["DS","1","BlockThickness"],"0x0102":["DS","1","BlockTransmission"],"0x0104":["IS","1","BlockNumberOfPoints"],"0x0106":["DS","2-2n","BlockData"],"0x0107":["SQ","1","ApplicatorSequence"],"0x0108":["SH","1","ApplicatorID"],"0x0109":["CS","1","ApplicatorType"],"0x010A":["LO","1","ApplicatorDescription"],"0x010C":["DS","1","CumulativeDoseReferenceCoefficient"],"0x010E":["DS","1","FinalCumulativeMetersetWeight"],"0x0110":["IS","1","NumberOfControlPoints"],"0x0111":["SQ","1","ControlPointSequence"],"0x0112":["IS","1","ControlPointIndex"],"0x0114":["DS","1","NominalBeamEnergy"],"0x0115":["DS","1","DoseRateSet"],"0x0116":["SQ","1","WedgePositionSequence"],"0x0118":["CS","1","WedgePosition"],"0x011A":["SQ","1","BeamLimitingDevicePositionSequence"],"0x011C":["DS","2-2n","LeafJawPositions"],"0x011E":["DS","1","GantryAngle"],"0x011F":["CS","1","GantryRotationDirection"],"0x0120":["DS","1","BeamLimitingDeviceAngle"],"0x0121":["CS","1","BeamLimitingDeviceRotationDirection"],"0x0122":["DS","1","PatientSupportAngle"],"0x0123":["CS","1","PatientSupportRotationDirection"],"0x0124":["DS","1","TableTopEccentricAxisDistance"],"0x0125":["DS","1","TableTopEccentricAngle"],"0x0126":["CS","1","TableTopEccentricRotationDirection"],"0x0128":["DS","1","TableTopVerticalPosition"],"0x0129":["DS","1","TableTopLongitudinalPosition"],"0x012A":["DS","1","TableTopLateralPosition"],"0x012C":["DS","3","IsocenterPosition"],"0x012E":["DS","3","SurfaceEntryPoint"],"0x0130":["DS","1","SourceToSurfaceDistance"],"0x0131":["FL","1","AverageBeamDosePointSourceToExternalContourDistance"],"0x0132":["FL","1","SourceToExternalContourDistance"],"0x0133":["FL","3","ExternalContourEntryPoint"],"0x0134":["DS","1","CumulativeMetersetWeight"],"0x0140":["FL","1","TableTopPitchAngle"],"0x0142":["CS","1","TableTopPitchRotationDirection"],"0x0144":["FL","1","TableTopRollAngle"],"0x0146":["CS","1","TableTopRollRotationDirection"],"0x0148":["FL","1","HeadFixationAngle"],"0x014A":["FL","1","GantryPitchAngle"],"0x014C":["CS","1","GantryPitchRotationDirection"],"0x014E":["FL","1","GantryPitchAngleTolerance"],"0x0150":["CS","1","FixationEye"],"0x0151":["DS","1","ChairHeadFramePosition"],"0x0152":["DS","1","HeadFixationAngleTolerance"],"0x0153":["DS","1","ChairHeadFramePositionTolerance"],"0x0154":["DS","1","FixationLightAzimuthalAngleTolerance"],"0x0155":["DS","1","FixationLightPolarAngleTolerance"],"0x0180":["SQ","1","PatientSetupSequence"],"0x0182":["IS","1","PatientSetupNumber"],"0x0183":["LO","1","PatientSetupLabel"],"0x0184":["LO","1","PatientAdditionalPosition"],"0x0190":["SQ","1","FixationDeviceSequence"],"0x0192":["CS","1","FixationDeviceType"],"0x0194":["SH","1","FixationDeviceLabel"],"0x0196":["ST","1","FixationDeviceDescription"],"0x0198":["SH","1","FixationDevicePosition"],"0x0199":["FL","1","FixationDevicePitchAngle"],"0x019A":["FL","1","FixationDeviceRollAngle"],"0x01A0":["SQ","1","ShieldingDeviceSequence"],"0x01A2":["CS","1","ShieldingDeviceType"],"0x01A4":["SH","1","ShieldingDeviceLabel"],"0x01A6":["ST","1","ShieldingDeviceDescription"],"0x01A8":["SH","1","ShieldingDevicePosition"],"0x01B0":["CS","1","SetupTechnique"],"0x01B2":["ST","1","SetupTechniqueDescription"],"0x01B4":["SQ","1","SetupDeviceSequence"],"0x01B6":["CS","1","SetupDeviceType"],"0x01B8":["SH","1","SetupDeviceLabel"],"0x01BA":["ST","1","SetupDeviceDescription"],"0x01BC":["DS","1","SetupDeviceParameter"],"0x01D0":["ST","1","SetupReferenceDescription"],"0x01D2":["DS","1","TableTopVerticalSetupDisplacement"],"0x01D4":["DS","1","TableTopLongitudinalSetupDisplacement"],"0x01D6":["DS","1","TableTopLateralSetupDisplacement"],"0x0200":["CS","1","BrachyTreatmentTechnique"],"0x0202":["CS","1","BrachyTreatmentType"],"0x0206":["SQ","1","TreatmentMachineSequence"],"0x0210":["SQ","1","SourceSequence"],"0x0212":["IS","1","SourceNumber"],"0x0214":["CS","1","SourceType"],"0x0216":["LO","1","SourceManufacturer"],"0x0218":["DS","1","ActiveSourceDiameter"],"0x021A":["DS","1","ActiveSourceLength"],"0x021B":["SH","1","SourceModelID"],"0x021C":["LO","1","SourceDescription"],"0x0222":["DS","1","SourceEncapsulationNominalThickness"],"0x0224":["DS","1","SourceEncapsulationNominalTransmission"],"0x0226":["LO","1","SourceIsotopeName"],"0x0228":["DS","1","SourceIsotopeHalfLife"],"0x0229":["CS","1","SourceStrengthUnits"],"0x022A":["DS","1","ReferenceAirKermaRate"],"0x022B":["DS","1","SourceStrength"],"0x022C":["DA","1","SourceStrengthReferenceDate"],"0x022E":["TM","1","SourceStrengthReferenceTime"],"0x0230":["SQ","1","ApplicationSetupSequence"],"0x0232":["CS","1","ApplicationSetupType"],"0x0234":["IS","1","ApplicationSetupNumber"],"0x0236":["LO","1","ApplicationSetupName"],"0x0238":["LO","1","ApplicationSetupManufacturer"],"0x0240":["IS","1","TemplateNumber"],"0x0242":["SH","1","TemplateType"],"0x0244":["LO","1","TemplateName"],"0x0250":["DS","1","TotalReferenceAirKerma"],"0x0260":["SQ","1","BrachyAccessoryDeviceSequence"],"0x0262":["IS","1","BrachyAccessoryDeviceNumber"],"0x0263":["SH","1","BrachyAccessoryDeviceID"],"0x0264":["CS","1","BrachyAccessoryDeviceType"],"0x0266":["LO","1","BrachyAccessoryDeviceName"],"0x026A":["DS","1","BrachyAccessoryDeviceNominalThickness"],"0x026C":["DS","1","BrachyAccessoryDeviceNominalTransmission"],"0x0271":["DS","1","ChannelEffectiveLength"],"0x0272":["DS","1","ChannelInnerLength"],"0x0273":["SH","1","AfterloaderChannelID"],"0x0274":["DS","1","SourceApplicatorTipLength"],"0x0280":["SQ","1","ChannelSequence"],"0x0282":["IS","1","ChannelNumber"],"0x0284":["DS","1","ChannelLength"],"0x0286":["DS","1","ChannelTotalTime"],"0x0288":["CS","1","SourceMovementType"],"0x028A":["IS","1","NumberOfPulses"],"0x028C":["DS","1","PulseRepetitionInterval"],"0x0290":["IS","1","SourceApplicatorNumber"],"0x0291":["SH","1","SourceApplicatorID"],"0x0292":["CS","1","SourceApplicatorType"],"0x0294":["LO","1","SourceApplicatorName"],"0x0296":["DS","1","SourceApplicatorLength"],"0x0298":["LO","1","SourceApplicatorManufacturer"],"0x029C":["DS","1","SourceApplicatorWallNominalThickness"],"0x029E":["DS","1","SourceApplicatorWallNominalTransmission"],"0x02A0":["DS","1","SourceApplicatorStepSize"],"0x02A1":["IS","1","ApplicatorShapeReferencedROINumber"],"0x02A2":["IS","1","TransferTubeNumber"],"0x02A4":["DS","1","TransferTubeLength"],"0x02B0":["SQ","1","ChannelShieldSequence"],"0x02B2":["IS","1","ChannelShieldNumber"],"0x02B3":["SH","1","ChannelShieldID"],"0x02B4":["LO","1","ChannelShieldName"],"0x02B8":["DS","1","ChannelShieldNominalThickness"],"0x02BA":["DS","1","ChannelShieldNominalTransmission"],"0x02C8":["DS","1","FinalCumulativeTimeWeight"],"0x02D0":["SQ","1","BrachyControlPointSequence"],"0x02D2":["DS","1","ControlPointRelativePosition"],"0x02D4":["DS","3","ControlPoint3DPosition"],"0x02D6":["DS","1","CumulativeTimeWeight"],"0x02E0":["CS","1","CompensatorDivergence"],"0x02E1":["CS","1","CompensatorMountingPosition"],"0x02E2":["DS","1-n","SourceToCompensatorDistance"],"0x02E3":["FL","1","TotalCompensatorTrayWaterEquivalentThickness"],"0x02E4":["FL","1","IsocenterToCompensatorTrayDistance"],"0x02E5":["FL","1","CompensatorColumnOffset"],"0x02E6":["FL","1-n","IsocenterToCompensatorDistances"],"0x02E7":["FL","1","CompensatorRelativeStoppingPowerRatio"],"0x02E8":["FL","1","CompensatorMillingToolDiameter"],"0x02EA":["SQ","1","IonRangeCompensatorSequence"],"0x02EB":["LT","1","CompensatorDescription"],"0x0302":["IS","1","RadiationMassNumber"],"0x0304":["IS","1","RadiationAtomicNumber"],"0x0306":["SS","1","RadiationChargeState"],"0x0308":["CS","1","ScanMode"],"0x0309":["CS","1","ModulatedScanModeType"],"0x030A":["FL","2","VirtualSourceAxisDistances"],"0x030C":["SQ","1","SnoutSequence"],"0x030D":["FL","1","SnoutPosition"],"0x030F":["SH","1","SnoutID"],"0x0312":["IS","1","NumberOfRangeShifters"],"0x0314":["SQ","1","RangeShifterSequence"],"0x0316":["IS","1","RangeShifterNumber"],"0x0318":["SH","1","RangeShifterID"],"0x0320":["CS","1","RangeShifterType"],"0x0322":["LO","1","RangeShifterDescription"],"0x0330":["IS","1","NumberOfLateralSpreadingDevices"],"0x0332":["SQ","1","LateralSpreadingDeviceSequence"],"0x0334":["IS","1","LateralSpreadingDeviceNumber"],"0x0336":["SH","1","LateralSpreadingDeviceID"],"0x0338":["CS","1","LateralSpreadingDeviceType"],"0x033A":["LO","1","LateralSpreadingDeviceDescription"],"0x033C":["FL","1","LateralSpreadingDeviceWaterEquivalentThickness"],"0x0340":["IS","1","NumberOfRangeModulators"],"0x0342":["SQ","1","RangeModulatorSequence"],"0x0344":["IS","1","RangeModulatorNumber"],"0x0346":["SH","1","RangeModulatorID"],"0x0348":["CS","1","RangeModulatorType"],"0x034A":["LO","1","RangeModulatorDescription"],"0x034C":["SH","1","BeamCurrentModulationID"],"0x0350":["CS","1","PatientSupportType"],"0x0352":["SH","1","PatientSupportID"],"0x0354":["LO","1","PatientSupportAccessoryCode"],"0x0355":["LO","1","TrayAccessoryCode"],"0x0356":["FL","1","FixationLightAzimuthalAngle"],"0x0358":["FL","1","FixationLightPolarAngle"],"0x035A":["FL","1","MetersetRate"],"0x0360":["SQ","1","RangeShifterSettingsSequence"],"0x0362":["LO","1","RangeShifterSetting"],"0x0364":["FL","1","IsocenterToRangeShifterDistance"],"0x0366":["FL","1","RangeShifterWaterEquivalentThickness"],"0x0370":["SQ","1","LateralSpreadingDeviceSettingsSequence"],"0x0372":["LO","1","LateralSpreadingDeviceSetting"],"0x0374":["FL","1","IsocenterToLateralSpreadingDeviceDistance"],"0x0380":["SQ","1","RangeModulatorSettingsSequence"],"0x0382":["FL","1","RangeModulatorGatingStartValue"],"0x0384":["FL","1","RangeModulatorGatingStopValue"],"0x0386":["FL","1","RangeModulatorGatingStartWaterEquivalentThickness"],"0x0388":["FL","1","RangeModulatorGatingStopWaterEquivalentThickness"],"0x038A":["FL","1","IsocenterToRangeModulatorDistance"],"0x038F":["FL","1-n","ScanSpotTimeOffset"],"0x0390":["SH","1","ScanSpotTuneID"],"0x0391":["IS","1-n","ScanSpotPrescribedIndices"],"0x0392":["IS","1","NumberOfScanSpotPositions"],"0x0393":["CS","1","ScanSpotReordered"],"0x0394":["FL","1-n","ScanSpotPositionMap"],"0x0395":["CS","1","ScanSpotReorderingAllowed"],"0x0396":["FL","1-n","ScanSpotMetersetWeights"],"0x0398":["FL","2","ScanningSpotSize"],"0x0399":["FL","2-2n","ScanSpotSizesDelivered"],"0x039A":["IS","1","NumberOfPaintings"],"0x03A0":["SQ","1","IonToleranceTableSequence"],"0x03A2":["SQ","1","IonBeamSequence"],"0x03A4":["SQ","1","IonBeamLimitingDeviceSequence"],"0x03A6":["SQ","1","IonBlockSequence"],"0x03A8":["SQ","1","IonControlPointSequence"],"0x03AA":["SQ","1","IonWedgeSequence"],"0x03AC":["SQ","1","IonWedgePositionSequence"],"0x0401":["SQ","1","ReferencedSetupImageSequence"],"0x0402":["ST","1","SetupImageComment"],"0x0410":["SQ","1","MotionSynchronizationSequence"],"0x0412":["FL","3","ControlPointOrientation"],"0x0420":["SQ","1","GeneralAccessorySequence"],"0x0421":["SH","1","GeneralAccessoryID"],"0x0422":["ST","1","GeneralAccessoryDescription"],"0x0423":["CS","1","GeneralAccessoryType"],"0x0424":["IS","1","GeneralAccessoryNumber"],"0x0425":["FL","1","SourceToGeneralAccessoryDistance"],"0x0426":["DS","1","IsocenterToGeneralAccessoryDistance"],"0x0431":["SQ","1","ApplicatorGeometrySequence"],"0x0432":["CS","1","ApplicatorApertureShape"],"0x0433":["FL","1","ApplicatorOpening"],"0x0434":["FL","1","ApplicatorOpeningX"],"0x0435":["FL","1","ApplicatorOpeningY"],"0x0436":["FL","1","SourceToApplicatorMountingPositionDistance"],"0x0440":["IS","1","NumberOfBlockSlabItems"],"0x0441":["SQ","1","BlockSlabSequence"],"0x0442":["DS","1","BlockSlabThickness"],"0x0443":["US","1","BlockSlabNumber"],"0x0450":["SQ","1","DeviceMotionControlSequence"],"0x0451":["CS","1","DeviceMotionExecutionMode"],"0x0452":["CS","1","DeviceMotionObservationMode"],"0x0453":["SQ","1","DeviceMotionParameterCodeSequence"],"0x0501":["FL","1","DistalDepthFraction"],"0x0502":["FL","1","DistalDepth"],"0x0503":["FL","2","NominalRangeModulationFractions"],"0x0504":["FL","2","NominalRangeModulatedRegionDepths"],"0x0505":["SQ","1","DepthDoseParametersSequence"],"0x0506":["SQ","1","DeliveredDepthDoseParametersSequence"],"0x0507":["FL","1","DeliveredDistalDepthFraction"],"0x0508":["FL","1","DeliveredDistalDepth"],"0x0509":["FL","2","DeliveredNominalRangeModulationFractions"],"0x0510":["FL","2","DeliveredNominalRangeModulatedRegionDepths"],"0x0511":["CS","1","DeliveredReferenceDoseDefinition"],"0x0512":["CS","1","ReferenceDoseDefinition"],"0x0600":["US","1","RTControlPointIndex"],"0x0601":["US","1","RadiationGenerationModeIndex"],"0x0602":["US","1","ReferencedDefinedDeviceIndex"],"0x0603":["US","1","RadiationDoseIdentificationIndex"],"0x0604":["US","1","NumberOfRTControlPoints"],"0x0605":["US","1","ReferencedRadiationGenerationModeIndex"],"0x0606":["US","1","TreatmentPositionIndex"],"0x0607":["US","1","ReferencedDeviceIndex"],"0x0608":["LO","1","TreatmentPositionGroupLabel"],"0x0609":["UI","1","TreatmentPositionGroupUID"],"0x060A":["SQ","1","TreatmentPositionGroupSequence"],"0x060B":["US","1","ReferencedTreatmentPositionIndex"],"0x060C":["US","1","ReferencedRadiationDoseIdentificationIndex"],"0x060D":["FD","1","RTAccessoryHolderWaterEquivalentThickness"],"0x060E":["US","1","ReferencedRTAccessoryHolderDeviceIndex"],"0x060F":["CS","1","RTAccessoryHolderSlotExistenceFlag"],"0x0610":["SQ","1","RTAccessoryHolderSlotSequence"],"0x0611":["LO","1","RTAccessoryHolderSlotID"],"0x0612":["FD","1","RTAccessoryHolderSlotDistance"],"0x0613":["FD","1","RTAccessorySlotDistance"],"0x0614":["SQ","1","RTAccessoryHolderDefinitionSequence"],"0x0615":["LO","1","RTAccessoryDeviceSlotID"],"0x0616":["SQ","1","RTRadiationSequence"],"0x0617":["SQ","1","RadiationDoseSequence"],"0x0618":["SQ","1","RadiationDoseIdentificationSequence"],"0x0619":["LO","1","RadiationDoseIdentificationLabel"],"0x061A":["CS","1","ReferenceDoseType"],"0x061B":["CS","1","PrimaryDoseValueIndicator"],"0x061C":["SQ","1","DoseValuesSequence"],"0x061D":["CS","1-n","DoseValuePurpose"],"0x061E":["FD","3","ReferenceDosePointCoordinates"],"0x061F":["SQ","1","RadiationDoseValuesParametersSequence"],"0x0620":["SQ","1","MetersetToDoseMappingSequence"],"0x0621":["SQ","1","ExpectedInVivoMeasurementValuesSequence"],"0x0622":["US","1","ExpectedInVivoMeasurementValueIndex"],"0x0623":["LO","1","RadiationDoseInVivoMeasurementLabel"],"0x0624":["FD","2","RadiationDoseCentralAxisDisplacement"],"0x0625":["FD","1","RadiationDoseValue"],"0x0626":["FD","1","RadiationDoseSourceToSkinDistance"],"0x0627":["FD","3","RadiationDoseMeasurementPointCoordinates"],"0x0628":["FD","1","RadiationDoseSourceToExternalContourDistance"],"0x0629":["SQ","1","RTToleranceSetSequence"],"0x062A":["LO","1","RTToleranceSetLabel"],"0x062B":["SQ","1","AttributeToleranceValuesSequence"],"0x062C":["FD","1","ToleranceValue"],"0x062D":["SQ","1","PatientSupportPositionToleranceSequence"],"0x062E":["FD","1","TreatmentTimeLimit"],"0x062F":["SQ","1","CArmPhotonElectronControlPointSequence"],"0x0630":["SQ","1","ReferencedRTRadiationSequence"],"0x0631":["SQ","1","ReferencedRTInstanceSequence"],"0x0632":["SQ","1","ReferencedRTPatientSetupSequence"],"0x0634":["FD","1","SourceToPatientSurfaceDistance"],"0x0635":["SQ","1","TreatmentMachineSpecialModeCodeSequence"],"0x0636":["US","1","IntendedNumberOfFractions"],"0x0637":["CS","1","RTRadiationSetIntent"],"0x0638":["CS","1","RTRadiationPhysicalAndGeometricContentDetailFlag"],"0x0639":["CS","1","RTRecordFlag"],"0x063A":["SQ","1","TreatmentDeviceIdentificationSequence"],"0x063B":["SQ","1","ReferencedRTPhysicianIntentSequence"],"0x063C":["FD","1","CumulativeMeterset"],"0x063D":["FD","1","DeliveryRate"],"0x063E":["SQ","1","DeliveryRateUnitSequence"],"0x063F":["SQ","1","TreatmentPositionSequence"],"0x0640":["FD","1","RadiationSourceAxisDistance"],"0x0641":["US","1","NumberOfRTBeamLimitingDevices"],"0x0642":["FD","1","RTBeamLimitingDeviceProximalDistance"],"0x0643":["FD","1","RTBeamLimitingDeviceDistalDistance"],"0x0644":["SQ","1","ParallelRTBeamDelimiterDeviceOrientationLabelCodeSequence"],"0x0645":["FD","1","BeamModifierOrientationAngle"],"0x0646":["SQ","1","FixedRTBeamDelimiterDeviceSequence"],"0x0647":["SQ","1","ParallelRTBeamDelimiterDeviceSequence"],"0x0648":["US","1","NumberOfParallelRTBeamDelimiters"],"0x0649":["FD","2-n","ParallelRTBeamDelimiterBoundaries"],"0x064A":["FD","2-n","ParallelRTBeamDelimiterPositions"],"0x064B":["FD","2","RTBeamLimitingDeviceOffset"],"0x064C":["SQ","1","RTBeamDelimiterGeometrySequence"],"0x064D":["SQ","1","RTBeamLimitingDeviceDefinitionSequence"],"0x064E":["CS","1","ParallelRTBeamDelimiterOpeningMode"],"0x064F":["CS","1-n","ParallelRTBeamDelimiterLeafMountingSide"],"0x0650":["UI","1","PatientSetupUID"],"0x0651":["SQ","1","WedgeDefinitionSequence"],"0x0652":["FD","1","RadiationBeamWedgeAngle"],"0x0653":["FD","1","RadiationBeamWedgeThinEdgeDistance"],"0x0654":["FD","1","RadiationBeamEffectiveWedgeAngle"],"0x0655":["US","1","NumberOfWedgePositions"],"0x0656":["SQ","1","RTBeamLimitingDeviceOpeningSequence"],"0x0657":["US","1","NumberOfRTBeamLimitingDeviceOpenings"],"0x0658":["SQ","1","RadiationDosimeterUnitSequence"],"0x0659":["SQ","1","RTDeviceDistanceReferenceLocationCodeSequence"],"0x065A":["SQ","1","RadiationDeviceConfigurationAndCommissioningKeySequence"],"0x065B":["SQ","1","PatientSupportPositionParameterSequence"],"0x065C":["CS","1","PatientSupportPositionSpecificationMethod"],"0x065D":["SQ","1","PatientSupportPositionDeviceParameterSequence"],"0x065E":["US","1","DeviceOrderIndex"],"0x065F":["US","1","PatientSupportPositionParameterOrderIndex"],"0x0660":["SQ","1","PatientSupportPositionDeviceToleranceSequence"],"0x0661":["US","1","PatientSupportPositionToleranceOrderIndex"],"0x0662":["SQ","1","CompensatorDefinitionSequence"],"0x0663":["CS","1","CompensatorMapOrientation"],"0x0664":["OF","1","CompensatorProximalThicknessMap"],"0x0665":["OF","1","CompensatorDistalThicknessMap"],"0x0666":["FD","1","CompensatorBasePlaneOffset"],"0x0667":["SQ","1","CompensatorShapeFabricationCodeSequence"],"0x0668":["SQ","1","CompensatorShapeSequence"],"0x0669":["FD","1","RadiationBeamCompensatorMillingToolDiameter"],"0x066A":["SQ","1","BlockDefinitionSequence"],"0x066B":["OF","1","BlockEdgeData"],"0x066C":["CS","1","BlockOrientation"],"0x066D":["FD","1","RadiationBeamBlockThickness"],"0x066E":["FD","1","RadiationBeamBlockSlabThickness"],"0x066F":["SQ","1","BlockEdgeDataSequence"],"0x0670":["US","1","NumberOfRTAccessoryHolders"],"0x0671":["SQ","1","GeneralAccessoryDefinitionSequence"],"0x0672":["US","1","NumberOfGeneralAccessories"],"0x0673":["SQ","1","BolusDefinitionSequence"],"0x0674":["US","1","NumberOfBoluses"],"0x0675":["UI","1","EquipmentFrameOfReferenceUID"],"0x0676":["ST","1","EquipmentFrameOfReferenceDescription"],"0x0677":["SQ","1","EquipmentReferencePointCoordinatesSequence"],"0x0678":["SQ","1","EquipmentReferencePointCodeSequence"],"0x0679":["FD","1","RTBeamLimitingDeviceAngle"],"0x067A":["FD","1","SourceRollAngle"],"0x067B":["SQ","1","RadiationGenerationModeSequence"],"0x067C":["SH","1","RadiationGenerationModeLabel"],"0x067D":["ST","1","RadiationGenerationModeDescription"],"0x067E":["SQ","1","RadiationGenerationModeMachineCodeSequence"],"0x067F":["SQ","1","RadiationTypeCodeSequence"],"0x0680":["DS","1","NominalEnergy"],"0x0681":["DS","1","MinimumNominalEnergy"],"0x0682":["DS","1","MaximumNominalEnergy"],"0x0683":["SQ","1","RadiationFluenceModifierCodeSequence"],"0x0684":["SQ","1","EnergyUnitCodeSequence"],"0x0685":["US","1","NumberOfRadiationGenerationModes"],"0x0686":["SQ","1","PatientSupportDevicesSequence"],"0x0687":["US","1","NumberOfPatientSupportDevices"],"0x0688":["FD","1","RTBeamModifierDefinitionDistance"],"0x0689":["SQ","1","BeamAreaLimitSequence"],"0x068A":["SQ","1","ReferencedRTPrescriptionSequence"],"0x0700":["UI","1","TreatmentSessionUID"],"0x0701":["CS","1","RTRadiationUsage"],"0x0702":["SQ","1","ReferencedRTRadiationSetSequence"],"0x0703":["SQ","1","ReferencedRTRadiationRecordSequence"],"0x0704":["US","1","RTRadiationSetDeliveryNumber"],"0x0705":["US","1","ClinicalFractionNumber"],"0x0706":["CS","1","RTTreatmentFractionCompletionStatus"],"0x0707":["CS","1","RTRadiationSetUsage"],"0x0708":["CS","1","TreatmentDeliveryContinuationFlag"],"0x0709":["CS","1","TreatmentRecordContentOrigin"],"0x0714":["CS","1","RTTreatmentTerminationStatus"],"0x0715":["SQ","1","RTTreatmentTerminationReasonCodeSequence"],"0x0716":["SQ","1","MachineSpecificTreatmentTerminationCodeSequence"],"0x0722":["SQ","1","RTRadiationSalvageRecordControlPointSequence"],"0x0723":["CS","1","StartingMetersetValueKnownFlag"],"0x0730":["ST","1","TreatmentTerminationDescription"],"0x0731":["SQ","1","TreatmentToleranceViolationSequence"],"0x0732":["CS","1","TreatmentToleranceViolationCategory"],"0x0733":["SQ","1","TreatmentToleranceViolationAttributeSequence"],"0x0734":["ST","1","TreatmentToleranceViolationDescription"],"0x0735":["ST","1","TreatmentToleranceViolationIdentification"],"0x0736":["DT","1","TreatmentToleranceViolationDateTime"],"0x073A":["DT","1","RecordedRTControlPointDateTime"],"0x073B":["US","1","ReferencedRadiationRTControlPointIndex"],"0x073E":["SQ","1","AlternateValueSequence"],"0x073F":["SQ","1","ConfirmationSequence"],"0x0740":["SQ","1","InterlockSequence"],"0x0741":["DT","1","InterlockDateTime"],"0x0742":["ST","1","InterlockDescription"],"0x0743":["SQ","1","InterlockOriginatingDeviceSequence"],"0x0744":["SQ","1","InterlockCodeSequence"],"0x0745":["SQ","1","InterlockResolutionCodeSequence"],"0x0746":["SQ","1","InterlockResolutionUserSequence"],"0x0760":["DT","1","OverrideDateTime"],"0x0761":["SQ","1","TreatmentToleranceViolationTypeCodeSequence"],"0x0762":["SQ","1","TreatmentToleranceViolationCauseCodeSequence"],"0x0772":["SQ","1","MeasuredMetersetToDoseMappingSequence"],"0x0773":["US","1","ReferencedExpectedInVivoMeasurementValueIndex"],"0x0774":["SQ","1","DoseMeasurementDeviceCodeSequence"],"0x0780":["SQ","1","AdditionalParameterRecordingInstanceSequence"],"0x0782":["US","1",""],"0x0783":["ST","1","InterlockOriginDescription"],"0x0784":["SQ","1","RTPatientPositionScopeSequence"],"0x0785":["UI","1","ReferencedTreatmentPositionGroupUID"],"0x0786":["US","1","RadiationOrderIndex"],"0x0787":["SQ","1","OmittedRadiationSequence"],"0x0788":["SQ","1","ReasonForOmissionCodeSequence"],"0x0789":["SQ","1","RTDeliveryStartPatientPositionSequence"],"0x078A":["SQ","1","RTTreatmentPreparationPatientPositionSequence"],"0x078B":["SQ","1","ReferencedRTTreatmentPreparationSequence"],"0x078C":["SQ","1","ReferencedPatientSetupPhotoSequence"],"0x078D":["SQ","1","PatientTreatmentPreparationMethodCodeSequence"],"0x078E":["LT","1","PatientTreatmentPreparationProcedureParameterDescription"],"0x078F":["SQ","1","PatientTreatmentPreparationDeviceSequence"],"0x0790":["SQ","1","PatientTreatmentPreparationProcedureSequence"],"0x0791":["SQ","1","PatientTreatmentPreparationProcedureCodeSequence"],"0x0792":["LT","1","PatientTreatmentPreparationMethodDescription"],"0x0793":["SQ","1","PatientTreatmentPreparationProcedureParameterSequence"],"0x0794":["LT","1","PatientSetupPhotoDescription"],"0x0795":["US","1","PatientTreatmentPreparationProcedureIndex"],"0x0796":["US","1","ReferencedPatientSetupProcedureIndex"],"0x0797":["SQ","1","RTRadiationTaskSequence"],"0x0798":["SQ","1","RTPatientPositionDisplacementSequence"],"0x0799":["SQ","1","RTPatientPositionSequence"],"0x079A":["LO","1","DisplacementReferenceLabel"],"0x079B":["FD","16","DisplacementMatrix"],"0x079C":["SQ","1","PatientSupportDisplacementSequence"],"0x079D":["SQ","1","DisplacementReferenceLocationCodeSequence"],"0x079E":["CS","1","RTRadiationSetDeliveryUsage"]},"0x300C":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["SQ","1","ReferencedRTPlanSequence"],"0x0004":["SQ","1","ReferencedBeamSequence"],"0x0006":["IS","1","ReferencedBeamNumber"],"0x0007":["IS","1","ReferencedReferenceImageNumber"],"0x0008":["DS","1","StartCumulativeMetersetWeight"],"0x0009":["DS","1","EndCumulativeMetersetWeight"],"0x000A":["SQ","1","ReferencedBrachyApplicationSetupSequence"],"0x000C":["IS","1","ReferencedBrachyApplicationSetupNumber"],"0x000E":["IS","1","ReferencedSourceNumber"],"0x0020":["SQ","1","ReferencedFractionGroupSequence"],"0x0022":["IS","1","ReferencedFractionGroupNumber"],"0x0040":["SQ","1","ReferencedVerificationImageSequence"],"0x0042":["SQ","1","ReferencedReferenceImageSequence"],"0x0050":["SQ","1","ReferencedDoseReferenceSequence"],"0x0051":["IS","1","ReferencedDoseReferenceNumber"],"0x0055":["SQ","1","BrachyReferencedDoseReferenceSequence"],"0x0060":["SQ","1","ReferencedStructureSetSequence"],"0x006A":["IS","1","ReferencedPatientSetupNumber"],"0x0080":["SQ","1","ReferencedDoseSequence"],"0x00A0":["IS","1","ReferencedToleranceTableNumber"],"0x00B0":["SQ","1","ReferencedBolusSequence"],"0x00C0":["IS","1","ReferencedWedgeNumber"],"0x00D0":["IS","1","ReferencedCompensatorNumber"],"0x00E0":["IS","1","ReferencedBlockNumber"],"0x00F0":["IS","1","ReferencedControlPointIndex"],"0x00F2":["SQ","1","ReferencedControlPointSequence"],"0x00F4":["IS","1","ReferencedStartControlPointIndex"],"0x00F6":["IS","1","ReferencedStopControlPointIndex"],"0x0100":["IS","1","ReferencedRangeShifterNumber"],"0x0102":["IS","1","ReferencedLateralSpreadingDeviceNumber"],"0x0104":["IS","1","ReferencedRangeModulatorNumber"],"0x0111":["SQ","1","OmittedBeamTaskSequence"],"0x0112":["CS","1","ReasonForOmission"],"0x0113":["LO","1","ReasonForOmissionDescription"],"0x0114":["SQ","1","PrescriptionOverviewSequence"],"0x0115":["FL","1","TotalPrescriptionDose"],"0x0116":["SQ","1","PlanOverviewSequence"],"0x0117":["US","1","PlanOverviewIndex"],"0x0118":["US","1","ReferencedPlanOverviewIndex"],"0x0119":["US","1","NumberOfFractionsIncluded"],"0x0120":["SQ","1","DoseCalibrationConditionsSequence"],"0x0121":["FD","1","AbsorbedDoseToMetersetRatio"],"0x0122":["FD","2","DelineatedRadiationFieldSize"],"0x0123":["CS","1","DoseCalibrationConditionsVerifiedFlag"],"0x0124":["FD","1","CalibrationReferencePointDepth"],"0x0125":["SQ","1","GatingBeamHoldTransitionSequence"],"0x0126":["CS","1","BeamHoldTransition"],"0x0127":["DT","1","BeamHoldTransitionDateTime"],"0x0128":["SQ","1","BeamHoldOriginatingDeviceSequence"]},"0x300E":{"0x0000":["UL","1","GenericGroupLength"],"0x0002":["CS","1","ApprovalStatus"],"0x0004":["DA","1","ReviewDate"],"0x0005":["TM","1","ReviewTime"],"0x0008":["PN","1","ReviewerName"]},"0x3010":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["SQ","1","RadiobiologicalDoseEffectSequence"],"0x0002":["CS","1","RadiobiologicalDoseEffectFlag"],"0x0003":["SQ","1","EffectiveDoseCalculationMethodCategoryCodeSequence"],"0x0004":["SQ","1","EffectiveDoseCalculationMethodCodeSequence"],"0x0005":["LO","1","EffectiveDoseCalculationMethodDescription"],"0x0006":["UI","1","ConceptualVolumeUID"],"0x0007":["SQ","1","OriginatingSOPInstanceReferenceSequence"],"0x0008":["SQ","1","ConceptualVolumeConstituentSequence"],"0x0009":["SQ","1","EquivalentConceptualVolumeInstanceReferenceSequence"],"0x000A":["SQ","1","EquivalentConceptualVolumesSequence"],"0x000B":["UI","1","ReferencedConceptualVolumeUID"],"0x000C":["UT","1","ConceptualVolumeCombinationExpression"],"0x000D":["US","1","ConceptualVolumeConstituentIndex"],"0x000E":["CS","1","ConceptualVolumeCombinationFlag"],"0x000F":["ST","1","ConceptualVolumeCombinationDescription"],"0x0010":["CS","1","ConceptualVolumeSegmentationDefinedFlag"],"0x0011":["SQ","1","ConceptualVolumeSegmentationReferenceSequence"],"0x0012":["SQ","1","ConceptualVolumeConstituentSegmentationReferenceSequence"],"0x0013":["UI","1","ConstituentConceptualVolumeUID"],"0x0014":["SQ","1","DerivationConceptualVolumeSequence"],"0x0015":["UI","1","SourceConceptualVolumeUID"],"0x0016":["SQ","1","ConceptualVolumeDerivationAlgorithmSequence"],"0x0017":["ST","1","ConceptualVolumeDescription"],"0x0018":["SQ","1","SourceConceptualVolumeSequence"],"0x0019":["SQ","1","AuthorIdentificationSequence"],"0x001A":["LO","1","ManufacturerModelVersion"],"0x001B":["UC","1","DeviceAlternateIdentifier"],"0x001C":["CS","1","DeviceAlternateIdentifierType"],"0x001D":["LT","1","DeviceAlternateIdentifierFormat"],"0x001E":["LO","1","SegmentationCreationTemplateLabel"],"0x001F":["UI","1","SegmentationTemplateUID"],"0x0020":["US","1","ReferencedSegmentReferenceIndex"],"0x0021":["SQ","1","SegmentReferenceSequence"],"0x0022":["US","1","SegmentReferenceIndex"],"0x0023":["SQ","1","DirectSegmentReferenceSequence"],"0x0024":["SQ","1","CombinationSegmentReferenceSequence"],"0x0025":["SQ","1","ConceptualVolumeSequence"],"0x0026":["SQ","1","SegmentedRTAccessoryDeviceSequence"],"0x0027":["SQ","1","SegmentCharacteristicsSequence"],"0x0028":["SQ","1","RelatedSegmentCharacteristicsSequence"],"0x0029":["US","1","SegmentCharacteristicsPrecedence"],"0x002A":["SQ","1","RTSegmentAnnotationSequence"],"0x002B":["SQ","1","SegmentAnnotationCategoryCodeSequence"],"0x002C":["SQ","1","SegmentAnnotationTypeCodeSequence"],"0x002D":["LO","1","DeviceLabel"],"0x002E":["SQ","1","DeviceTypeCodeSequence"],"0x002F":["SQ","1","SegmentAnnotationTypeModifierCodeSequence"],"0x0030":["SQ","1","PatientEquipmentRelationshipCodeSequence"],"0x0031":["UI","1","ReferencedFiducialsUID"],"0x0032":["SQ","1","PatientTreatmentOrientationSequence"],"0x0033":["SH","1","UserContentLabel"],"0x0034":["LO","1","UserContentLongLabel"],"0x0035":["SH","1","EntityLabel"],"0x0036":["LO","1","EntityName"],"0x0037":["ST","1","EntityDescription"],"0x0038":["LO","1","EntityLongLabel"],"0x0039":["US","1","DeviceIndex"],"0x003A":["US","1","RTTreatmentPhaseIndex"],"0x003B":["UI","1","RTTreatmentPhaseUID"],"0x003C":["US","1","RTPrescriptionIndex"],"0x003D":["US","1","RTSegmentAnnotationIndex"],"0x003E":["US","1","BasisRTTreatmentPhaseIndex"],"0x003F":["US","1","RelatedRTTreatmentPhaseIndex"],"0x0040":["US","1","ReferencedRTTreatmentPhaseIndex"],"0x0041":["US","1","ReferencedRTPrescriptionIndex"],"0x0042":["US","1","ReferencedParentRTPrescriptionIndex"],"0x0043":["ST","1","ManufacturerDeviceIdentifier"],"0x0044":["SQ","1","InstanceLevelReferencedPerformedProcedureStepSequence"],"0x0045":["CS","1","RTTreatmentPhaseIntentPresenceFlag"],"0x0046":["CS","1","RadiotherapyTreatmentType"],"0x0047":["CS","1-n","TeletherapyRadiationType"],"0x0048":["CS","1-n","BrachytherapySourceType"],"0x0049":["SQ","1","ReferencedRTTreatmentPhaseSequence"],"0x004A":["SQ","1","ReferencedDirectSegmentInstanceSequence"],"0x004B":["SQ","1","IntendedRTTreatmentPhaseSequence"],"0x004C":["DA","1","IntendedPhaseStartDate"],"0x004D":["DA","1","IntendedPhaseEndDate"],"0x004E":["SQ","1","RTTreatmentPhaseIntervalSequence"],"0x004F":["CS","1","TemporalRelationshipIntervalAnchor"],"0x0050":["FD","1","MinimumNumberOfIntervalDays"],"0x0051":["FD","1","MaximumNumberOfIntervalDays"],"0x0052":["UI","1-n","PertinentSOPClassesInStudy"],"0x0053":["UI","1-n","PertinentSOPClassesInSeries"],"0x0054":["LO","1","RTPrescriptionLabel"],"0x0055":["SQ","1","RTPhysicianIntentPredecessorSequence"],"0x0056":["LO","1","RTTreatmentApproachLabel"],"0x0057":["SQ","1","RTPhysicianIntentSequence"],"0x0058":["US","1","RTPhysicianIntentIndex"],"0x0059":["CS","1","RTTreatmentIntentType"],"0x005A":["UT","1","RTPhysicianIntentNarrative"],"0x005B":["SQ","1","RTProtocolCodeSequence"],"0x005C":["ST","1","ReasonForSuperseding"],"0x005D":["SQ","1","RTDiagnosisCodeSequence"],"0x005E":["US","1","ReferencedRTPhysicianIntentIndex"],"0x005F":["SQ","1","RTPhysicianIntentInputInstanceSequence"],"0x0060":["SQ","1","RTAnatomicPrescriptionSequence"],"0x0061":["UT","1","PriorTreatmentDoseDescription"],"0x0062":["SQ","1","PriorTreatmentReferenceSequence"],"0x0063":["CS","1","DosimetricObjectiveEvaluationScope"],"0x0064":["SQ","1","TherapeuticRoleCategoryCodeSequence"],"0x0065":["SQ","1","TherapeuticRoleTypeCodeSequence"],"0x0066":["US","1","ConceptualVolumeOptimizationPrecedence"],"0x0067":["SQ","1","ConceptualVolumeCategoryCodeSequence"],"0x0068":["CS","1","ConceptualVolumeBlockingConstraint"],"0x0069":["SQ","1","ConceptualVolumeTypeCodeSequence"],"0x006A":["SQ","1","ConceptualVolumeTypeModifierCodeSequence"],"0x006B":["SQ","1","RTPrescriptionSequence"],"0x006C":["SQ","1","DosimetricObjectiveSequence"],"0x006D":["SQ","1","DosimetricObjectiveTypeCodeSequence"],"0x006E":["UI","1","DosimetricObjectiveUID"],"0x006F":["UI","1","ReferencedDosimetricObjectiveUID"],"0x0070":["SQ","1","DosimetricObjectiveParameterSequence"],"0x0071":["SQ","1","ReferencedDosimetricObjectivesSequence"],"0x0073":["CS","1","AbsoluteDosimetricObjectiveFlag"],"0x0074":["FD","1","DosimetricObjectiveWeight"],"0x0075":["CS","1","DosimetricObjectivePurpose"],"0x0076":["SQ","1","PlanningInputInformationSequence"],"0x0077":["LO","1","TreatmentSite"],"0x0078":["SQ","1","TreatmentSiteCodeSequence"],"0x0079":["SQ","1","FractionPatternSequence"],"0x007A":["UT","1","TreatmentTechniqueNotes"],"0x007B":["UT","1","PrescriptionNotes"],"0x007C":["IS","1","NumberOfIntervalFractions"],"0x007D":["US","1","NumberOfFractions"],"0x007E":["US","1","IntendedDeliveryDuration"],"0x007F":["UT","1","FractionationNotes"],"0x0080":["SQ","1","RTTreatmentTechniqueCodeSequence"],"0x0081":["SQ","1","PrescriptionNotesSequence"],"0x0082":["SQ","1","FractionBasedRelationshipSequence"],"0x0083":["CS","1","FractionBasedRelationshipIntervalAnchor"],"0x0084":["FD","1","MinimumHoursBetweenFractions"],"0x0085":["TM","1-n","IntendedFractionStartTime"],"0x0086":["LT","1","IntendedStartDayOfWeek"],"0x0087":["SQ","1","WeekdayFractionPatternSequence"],"0x0088":["SQ","1","DeliveryTimeStructureCodeSequence"],"0x0089":["SQ","1","TreatmentSiteModifierCodeSequence"],"0x0090":["CS","1","RoboticBaseLocationIndicator"],"0x0091":["SQ","1","RoboticPathNodeSetCodeSequence"],"0x0092":["UL","1","RoboticNodeIdentifier"],"0x0093":["FD","3","RTTreatmentSourceCoordinates"],"0x0094":["FD","1","RadiationSourceCoordinateSystemYawAngle"],"0x0095":["FD","1","RadiationSourceCoordinateSystemRollAngle"],"0x0096":["FD","1","RadiationSourceCoordinateSystemPitchAngle"],"0x0097":["SQ","1","RoboticPathControlPointSequence"],"0x0098":["SQ","1","TomotherapeuticControlPointSequence"],"0x0099":["FD","1-n","TomotherapeuticLeafOpenDurations"],"0x009A":["FD","1-n","TomotherapeuticLeafInitialClosedDurations"]},"0x4000":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["LT","1","Arbitrary"],"0x4000":["LT","1","TextComments"]},"0x4008":{"0x0000":["UL","1","GenericGroupLength"],"0x0040":["SH","1","ResultsID"],"0x0042":["LO","1","ResultsIDIssuer"],"0x0050":["SQ","1","ReferencedInterpretationSequence"],"0x00FF":["CS","1","ReportProductionStatusTrial"],"0x0100":["DA","1","InterpretationRecordedDate"],"0x0101":["TM","1","InterpretationRecordedTime"],"0x0102":["PN","1","InterpretationRecorder"],"0x0103":["LO","1","ReferenceToRecordedSound"],"0x0108":["DA","1","InterpretationTranscriptionDate"],"0x0109":["TM","1","InterpretationTranscriptionTime"],"0x010A":["PN","1","InterpretationTranscriber"],"0x010B":["ST","1","InterpretationText"],"0x010C":["PN","1","InterpretationAuthor"],"0x0111":["SQ","1","InterpretationApproverSequence"],"0x0112":["DA","1","InterpretationApprovalDate"],"0x0113":["TM","1","InterpretationApprovalTime"],"0x0114":["PN","1","PhysicianApprovingInterpretation"],"0x0115":["LT","1","InterpretationDiagnosisDescription"],"0x0117":["SQ","1","InterpretationDiagnosisCodeSequence"],"0x0118":["SQ","1","ResultsDistributionListSequence"],"0x0119":["PN","1","DistributionName"],"0x011A":["LO","1","DistributionAddress"],"0x0200":["SH","1","InterpretationID"],"0x0202":["LO","1","InterpretationIDIssuer"],"0x0210":["CS","1","InterpretationTypeID"],"0x0212":["CS","1","InterpretationStatusID"],"0x0300":["ST","1","Impressions"],"0x4000":["ST","1","ResultsComments"]},"0x4010":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["CS","1","LowEnergyDetectors"],"0x0002":["CS","1","HighEnergyDetectors"],"0x0004":["SQ","1","DetectorGeometrySequence"],"0x1001":["SQ","1","ThreatROIVoxelSequence"],"0x1004":["FL","3","ThreatROIBase"],"0x1005":["FL","3","ThreatROIExtents"],"0x1006":["OB","1","ThreatROIBitmap"],"0x1007":["SH","1","RouteSegmentID"],"0x1008":["CS","1","GantryType"],"0x1009":["CS","1","OOIOwnerType"],"0x100A":["SQ","1","RouteSegmentSequence"],"0x1010":["US","1","PotentialThreatObjectID"],"0x1011":["SQ","1","ThreatSequence"],"0x1012":["CS","1","ThreatCategory"],"0x1013":["LT","1","ThreatCategoryDescription"],"0x1014":["CS","1","ATDAbilityAssessment"],"0x1015":["CS","1","ATDAssessmentFlag"],"0x1016":["FL","1","ATDAssessmentProbability"],"0x1017":["FL","1","Mass"],"0x1018":["FL","1","Density"],"0x1019":["FL","1","ZEffective"],"0x101A":["SH","1","BoardingPassID"],"0x101B":["FL","3","CenterOfMass"],"0x101C":["FL","3","CenterOfPTO"],"0x101D":["FL","6-n","BoundingPolygon"],"0x101E":["SH","1","RouteSegmentStartLocationID"],"0x101F":["SH","1","RouteSegmentEndLocationID"],"0x1020":["CS","1","RouteSegmentLocationIDType"],"0x1021":["CS","1-n","AbortReason"],"0x1023":["FL","1","VolumeOfPTO"],"0x1024":["CS","1","AbortFlag"],"0x1025":["DT","1","RouteSegmentStartTime"],"0x1026":["DT","1","RouteSegmentEndTime"],"0x1027":["CS","1","TDRType"],"0x1028":["CS","1","InternationalRouteSegment"],"0x1029":["LO","1-n","ThreatDetectionAlgorithmAndVersion"],"0x102A":["SH","1","AssignedLocation"],"0x102B":["DT","1","AlarmDecisionTime"],"0x1031":["CS","1","AlarmDecision"],"0x1033":["US","1","NumberOfTotalObjects"],"0x1034":["US","1","NumberOfAlarmObjects"],"0x1037":["SQ","1","PTORepresentationSequence"],"0x1038":["SQ","1","ATDAssessmentSequence"],"0x1039":["CS","1","TIPType"],"0x103A":["CS","1","DICOSVersion"],"0x1041":["DT","1","OOIOwnerCreationTime"],"0x1042":["CS","1","OOIType"],"0x1043":["FL","3","OOISize"],"0x1044":["CS","1","AcquisitionStatus"],"0x1045":["SQ","1","BasisMaterialsCodeSequence"],"0x1046":["CS","1","PhantomType"],"0x1047":["SQ","1","OOIOwnerSequence"],"0x1048":["CS","1","ScanType"],"0x1051":["LO","1","ItineraryID"],"0x1052":["SH","1","ItineraryIDType"],"0x1053":["LO","1","ItineraryIDAssigningAuthority"],"0x1054":["SH","1","RouteID"],"0x1055":["SH","1","RouteIDAssigningAuthority"],"0x1056":["CS","1","InboundArrivalType"],"0x1058":["SH","1","CarrierID"],"0x1059":["CS","1","CarrierIDAssigningAuthority"],"0x1060":["FL","3","SourceOrientation"],"0x1061":["FL","3","SourcePosition"],"0x1062":["FL","1","BeltHeight"],"0x1064":["SQ","1","AlgorithmRoutingCodeSequence"],"0x1067":["CS","1","TransportClassification"],"0x1068":["LT","1","OOITypeDescriptor"],"0x1069":["FL","1","TotalProcessingTime"],"0x106C":["OB","1","DetectorCalibrationData"],"0x106D":["CS","1","AdditionalScreeningPerformed"],"0x106E":["CS","1","AdditionalInspectionSelectionCriteria"],"0x106F":["SQ","1","AdditionalInspectionMethodSequence"],"0x1070":["CS","1","AITDeviceType"],"0x1071":["SQ","1","QRMeasurementsSequence"],"0x1072":["SQ","1","TargetMaterialSequence"],"0x1073":["FD","1","SNRThreshold"],"0x1075":["DS","1","ImageScaleRepresentation"],"0x1076":["SQ","1","ReferencedPTOSequence"],"0x1077":["SQ","1","ReferencedTDRInstanceSequence"],"0x1078":["ST","1","PTOLocationDescription"],"0x1079":["SQ","1","AnomalyLocatorIndicatorSequence"],"0x107A":["FL","3","AnomalyLocatorIndicator"],"0x107B":["SQ","1","PTORegionSequence"],"0x107C":["CS","1","InspectionSelectionCriteria"],"0x107D":["SQ","1","SecondaryInspectionMethodSequence"],"0x107E":["DS","6","PRCSToRCSOrientation"]},"0x4FFE":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["SQ","1","MACParametersSequence"]},"0x5000":{"0x0000":["UL","1","GenericGroupLength"],"0x0005":["US","1","CurveDimensions"],"0x0010":["US","1","NumberOfPoints"],"0x0020":["CS","1","TypeOfData"],"0x0022":["LO","1","CurveDescription"],"0x0030":["SH","1-n","AxisUnits"],"0x0040":["SH","1-n","AxisLabels"],"0x0103":["US","1","DataValueRepresentation"],"0x0104":["US","1-n","MinimumCoordinateValue"],"0x0105":["US","1-n","MaximumCoordinateValue"],"0x0106":["SH","1-n","CurveRange"],"0x0110":["US","1-n","CurveDataDescriptor"],"0x0112":["US","1-n","CoordinateStartValue"],"0x0114":["US","1-n","CoordinateStepValue"],"0x1001":["CS","1","CurveActivationLayer"],"0x2000":["US","1","AudioType"],"0x2002":["US","1","AudioSampleFormat"],"0x2004":["US","1","NumberOfChannels"],"0x2006":["UL","1","NumberOfSamples"],"0x2008":["UL","1","SampleRate"],"0x200A":["UL","1","TotalTime"],"0x200C":["ox","1","AudioSampleData"],"0x200E":["LT","1","AudioComments"],"0x2500":["LO","1","CurveLabel"],"0x2600":["SQ","1","CurveReferencedOverlaySequence"],"0x2610":["US","1","CurveReferencedOverlayGroup"],"0x3000":["ox","1","CurveData"]},"0x5200":{"0x0000":["UL","1","GenericGroupLength"],"0x9229":["SQ","1","SharedFunctionalGroupsSequence"],"0x9230":["SQ","1","PerFrameFunctionalGroupsSequence"]},"0x5400":{"0x0000":["UL","1","GenericGroupLength"],"0x0100":["SQ","1","WaveformSequence"],"0x0110":["ox","1","ChannelMinimumValue"],"0x0112":["ox","1","ChannelMaximumValue"],"0x1004":["US","1","WaveformBitsAllocated"],"0x1006":["CS","1","WaveformSampleInterpretation"],"0x100A":["ox","1","WaveformPaddingValue"],"0x1010":["ox","1","WaveformData"]},"0x5600":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["OF","1","FirstOrderPhaseCorrectionAngle"],"0x0020":["OF","1","SpectroscopyData"]},"0x6000":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["US","1","OverlayRows"],"0x0011":["US","1","OverlayColumns"],"0x0012":["US","1","OverlayPlanes"],"0x0015":["IS","1","NumberOfFramesInOverlay"],"0x0022":["LO","1","OverlayDescription"],"0x0040":["CS","1","OverlayType"],"0x0045":["LO","1","OverlaySubtype"],"0x0050":["SS","2","OverlayOrigin"],"0x0051":["US","1","ImageFrameOrigin"],"0x0052":["US","1","OverlayPlaneOrigin"],"0x0060":["CS","1","OverlayCompressionCode"],"0x0061":["SH","1","OverlayCompressionOriginator"],"0x0062":["SH","1","OverlayCompressionLabel"],"0x0063":["CS","1","OverlayCompressionDescription"],"0x0066":["AT","1-n","OverlayCompressionStepPointers"],"0x0068":["US","1","OverlayRepeatInterval"],"0x0069":["US","1","OverlayBitsGrouped"],"0x0100":["US","1","OverlayBitsAllocated"],"0x0102":["US","1","OverlayBitPosition"],"0x0110":["CS","1","OverlayFormat"],"0x0200":["US","1","OverlayLocation"],"0x0800":["CS","1-n","OverlayCodeLabel"],"0x0802":["US","1","OverlayNumberOfTables"],"0x0803":["AT","1-n","OverlayCodeTableLocation"],"0x0804":["US","1","OverlayBitsForCodeWord"],"0x1001":["CS","1","OverlayActivationLayer"],"0x1100":["US","1","OverlayDescriptorGray"],"0x1101":["US","1","OverlayDescriptorRed"],"0x1102":["US","1","OverlayDescriptorGreen"],"0x1103":["US","1","OverlayDescriptorBlue"],"0x1200":["US","1-n","OverlaysGray"],"0x1201":["US","1-n","OverlaysRed"],"0x1202":["US","1-n","OverlaysGreen"],"0x1203":["US","1-n","OverlaysBlue"],"0x1301":["IS","1","ROIArea"],"0x1302":["DS","1","ROIMean"],"0x1303":["DS","1","ROIStandardDeviation"],"0x1500":["LO","1","OverlayLabel"],"0x3000":["ox","1","OverlayData"],"0x4000":["LT","1","OverlayComments"]},"0x7F00":{"0x0000":["UL","1","GenericGroupLength"],"0x0010":["ox","1","VariablePixelData"],"0x0011":["US","1","VariableNextDataGroup"],"0x0020":["OW","1","VariableCoefficientsSDVN"],"0x0030":["OW","1","VariableCoefficientsSDHN"],"0x0040":["OW","1","VariableCoefficientsSDDN"]},"0x7FE0":{"0x0000":["UL","1","GenericGroupLength"],"0x0001":["OV","1","ExtendedOffsetTable"],"0x0002":["OV","1","ExtendedOffsetTableLengths"],"0x0008":["OF","1","FloatPixelData"],"0x0009":["OD","1","DoubleFloatPixelData"],"0x0010":["ox","1","PixelData"],"0x0020":["OW","1","CoefficientsSDVN"],"0x0030":["OW","1","CoefficientsSDHN"],"0x0040":["OW","1","CoefficientsSDDN"]},"0xFFFA":{"0x0000":["UL","1","GenericGroupLength"],"0xFFFA":["SQ","1","DigitalSignaturesSequence"]},"0xFFFC":{"0x0000":["UL","1","GenericGroupLength"],"0xFFFC":["OB","1","DataSetTrailingPadding"]},"0xFFFE":{"0x0000":["UL","1","GenericGroupLength"],"0xE000":["NONE","1","Item"],"0xE00D":["NONE","1","ItemDelimitationItem"],"0xE0DD":["NONE","1","SequenceDelimitationItem"]}},_.dicom.TagGroups={x0000:"Command",x0002:"Meta Element",x0004:"File Set",x0008:"Identifying",x0009:"SPI Identifying",x0010:"Patient",x0012:"Clinical Trial",x0018:"Acquisition",x0019:"SPI Acquisition",x0020:"Image",x0021:"SPI Image",x0022:"Ophtalmology",x0028:"Image Presentation",x0032:"Study",x0038:"Visit",x003A:"Waveform",x0040:"Procedure",x0042:"Encapsulated Document",x0050:"Device Informations",x0054:"Nuclear Medicine",x0060:"Histogram",x0070:"Presentation State",x0072:"Hanging Protocol",x0088:"Storage",x0100:"Authorization",x0400:"Digital Signature",x1000:"Code Table",x1010:"Zonal Map",x2000:"Film Session",x2010:"Film Box",x2020:"Image Box",x2030:"Annotation",x2040:"Overlay Box",x2050:"Presentation LUT",x2100:"Print Job",x2110:"Printer",x2120:"Queue",x2130:"Print Content",x2200:"Media Creation",x3002:"RT Image",x3004:"RT Dose",x3006:"RT StructureSet",x3008:"RT Treatment",x300A:"RT Plan",x300C:"RT Relationship",x300E:"RT Approval",x4000:"Text",x4008:"Results",x4FFE:"MAC Parameters",x5000:"Curve",x5002:"Curve",x5004:"Curve",x5006:"Curve",x5008:"Curve",x500A:"Curve",x500C:"Curve",x500E:"Curve",x5400:"Waveform Data",x6000:"Overlays",x6002:"Overlays",x6004:"Overlays",x6008:"Overlays",x600A:"Overlays",x600C:"Overlays",x600E:"Overlays",xFFFC:"Generic",x7FE0:"Pixel Data",xFFFF:"Unknown"},_.dicom.vr32bitVL=["OB","OD","OF","OL","OV","OW","SQ","SV","UC","UN","UR","UT","UV","ox"],_.dicom.charSetString=["SH","LO","UC","ST","LT","UT","PN"],_.dicom.vrTypes={AE:"string",AS:"string",AT:void 0,CS:"string",DA:"string",DS:"string",DT:"string",FL:"Float32",FD:"Float64",IS:"string",LO:"string",LT:"string",OB:"Uint8",OD:"Uint64",OF:"Uint32",OL:"Uint32",OV:"Uint64",OW:"Uint16",PN:"string",SH:"string",SL:"Int32",SQ:void 0,SS:"Int16",ST:"string",SV:"Int64",TM:"string",UC:"string",UI:"string",UL:"Uint32",UN:"Uint8",UR:"string",US:"Uint16",UT:"string",UV:"Uint64"},_||{}),L=(_.gui=_.gui||{},L||{}),_=(_.gui.DrawLayer=function(i){i.className+=" drawLayer";var r,o,u,t=this,l=null,c={x:1,y:1},d={x:0,y:0},a={x:0,y:0},g={x:0,y:0},s={x:0,y:0},x=null,S=null,n=(this.getDataIndex=function(){return S},new _.utils.ListenerHandler);function m(e){e.srclayerid=t.getId(),e.dataid=S,n.fireEvent(e)}this.getKonvaStage=function(){return l},this.getKonvaLayer=function(){return l.getLayers()[0]},this.getDrawController=function(){return x},this.setPlaneHelper=function(e){u=e},this.getId=function(){return i.id},this.getBaseSize=function(){return r},this.getOpacity=function(){return l.opacity()},this.setOpacity=function(e){l.opacity(Math.min(Math.max(e,0),1))},this.addFlipOffsetX=function(){var e=l.scale(),t=l.size(),t=(s.x+=t.width/e.x,l.offset());t.x+=s.x,l.offset(t)},this.addFlipOffsetY=function(){var e=l.scale(),t=l.size(),t=(s.y+=t.height/e.y,l.offset());t.y+=s.y,l.offset(t)},this.setScale=function(e,t){for(var n=u.getTargetOrientedPositiveXYZ(e),n={x:c.x*n.x,y:c.y*n.y},i=l.offset(),i=(1===Math.abs(e.x)&&1===Math.abs(e.y)&&1===Math.abs(e.z)?(e={x:i.x-g.x,y:i.y-g.y},g={x:0,y:0},l.offset(e)):void 0!==t&&(e={x:(e=u.getPlaneOffsetFromOffset3D({x:t.getX(),y:t.getY(),z:t.getZ()})).x+d.x,y:e.y+d.y},t=_.gui.getScaledOffset(i,l.scale(),n,e),e={x:g.x+t.x-i.x,y:g.y+t.y-i.y},g=e,l.offset(t)),l.scale(n),n),r=2/i.x,o=2/i.y,a=l.find("Label"),s=0;s<a.length;++s)a[s].scale({x:r,y:o})},this.setOffset=function(e){e=u.getPlaneOffsetFromOffset3D(e);l.offset({x:e.x+a.x+d.x+g.x+s.x,y:e.y+a.y+d.y+g.y+s.y})},this.setBaseOffset=function(e,t){var n=u.getNativeScrollIndex(),n=u.getPlaneOffsetFromOffset3D({x:(0===n?e:t).getX(),y:(1===n?e:t).getY(),z:(2===n?e:t).getZ()}),e=d.x!==n.x||d.y!==n.y;return e&&(t=l.offset(),l.offset({x:t.x-d.x+n.x,y:t.y-d.y+n.y}),d=n),e},this.display=function(e){i.style.display=e?"":"none"},this.isVisible=function(){return""===i.style.display},this.draw=function(){l.draw()},this.initialise=function(e,t,n){r=e,o=t,S=n,(l=new L.Stage({container:i,width:r.x,height:r.y,listening:!1})).getContent().setAttribute("style","");e=new L.Layer({listening:!1,visible:!0});l.add(e),x=new _.ctrl.DrawController(e)},this.fitToContainer=function(e,t,n){l.setWidth(t.x),l.setHeight(t.y);var t=l.scale().x/c.x,i=l.scale().y/c.y;c={x:e*o.x,y:e*o.y},l.scale({x:t*c.x,y:i*c.y}),a={x:n.x/c.x,y:n.y/c.y},l.offset({x:a.x+d.x+g.x+s.x,y:a.y+d.y+g.y+s.y})},this.isGroupVisible=function(e){e=x.getGroup(e);return void 0!==e&&e.isVisible()},this.toogleGroupVisibility=function(e){e=x.getGroup(e);return void 0!==e&&(e.visible(!e.isVisible()),this.draw(),!0)},this.deleteDraw=function(e,t){x.deleteDraw(e,m,t)},this.deleteDraws=function(e){x.deleteDraws(m,e)},this.bindInteraction=function(){l.listening(!0),i.style.pointerEvents="auto";for(var e=_.gui.interactionEventNames,t=0;t<e.length;++t)i.addEventListener(e[t],m)},this.unbindInteraction=function(){l.listening(!1),i.style.pointerEvents="none";for(var e=_.gui.interactionEventNames,t=0;t<e.length;++t)i.removeEventListener(e[t],m)},this.setCurrentPosition=function(e,t){return this.getDrawController().activateDrawLayer(t,u.getScrollIndex()),!0},this.addEventListener=function(e,t){n.add(e,t)},this.removeEventListener=function(e,t){n.remove(e,t)}},_||{}),_=(_.gui=_.gui||{},_.gui.interactionEventNames=["mousedown","mousemove","mouseup","mouseout","wheel","dblclick","touchstart","touchmove","touchend"],_.gui.getElement=function(e,t){var n=document.getElementById(e);if(!n)return null;n=n.getElementsByClassName(t),n=n[n.length-1];return n=void 0===n?document.getElementById(e+"-"+t):n},_.getElement=_.gui.getElement,_.gui.prompt=function(e,t){return prompt(e,t)},_.prompt=_.gui.prompt,_.openRoiDialog,_.gui.getTouchesPositions=function(e){var t=0,n=0;if(0!==e.length&&void 0!==e[0].target)for(var i=e[0].target.offsetParent;i;)isNaN(i.offsetLeft)||(t+=i.offsetLeft),isNaN(i.offsetTop)||(n+=i.offsetTop),i=i.offsetParent;else _.logger.debug("No touch target offset parent.");for(var r=[],o=0;o<e.length;++o)r.push({x:e[o].pageX-t,y:e[o].pageY-n});return r},_.gui.getEventOffset=function(e){var t=[];return void 0!==e.targetTouches&&0!==e.targetTouches.length?t=_.gui.getTouchesPositions(e.targetTouches):void 0!==e.changedTouches&&0!==e.changedTouches.length?t=_.gui.getTouchesPositions(e.changedTouches):t.push({x:e.offsetX,y:e.offsetY}),t},_.gui.canCreateCanvas=function(e,t){var n=document.createElement("canvas"),i=(n.width=e,n.height=t,document.createElement("canvas")),r=(i.width=1,i.height=1,n.getContext("2d")),i=i.getContext("2d");return r&&(r.fillRect(e-1,t-1,1,1),i.drawImage(n,e-1,t-1,1,1,0,0,1,1)),i&&0!==i.getImageData(0,0,1,1).data[3]},_||{}),_=(_.gui=_.gui||{},_.gui.getLayerDivId=function(e,t){return e+"-layer-"+t},_.gui.getLayerDetailsFromLayerDivId=function(e){e=e.split("-layer-");return 2!==e.length&&_.logger.warn("Not the expected layer div id format..."),{groupDivId:e[0],layerId:e[1]}},_.gui.getLayerDetailsFromEvent=function(e){var t=null,e=e.target.closest(".layer");return t=e&&void 0!==e.id?_.gui.getLayerDetailsFromLayerDivId(e.id):t},_.gui.getViewOrientation=function(e,t){var n=_.math.getIdentityMat33();return(n=void 0!==t?e.asOneAndZeros().getInverse().multiply(t):n).getAbs()},_.gui.getTargetOrientation=function(e,t){t=e.asOneAndZeros().multiply(t);return t=e.asOneAndZeros().getAbs().equals(_.math.getCoronalMat33().getAbs())?t.getAbs():t},_.gui.getScaledOffset=function(e,t,n,i){var r=(i.x-e.x)*t.x,e=(i.y-e.y)*t.y;return{x:i.x-r/n.x,y:i.y-e/n.y}},_.gui.LayerGroup=function(o){var t,x,S=this,m=[],i={x:1,y:1,z:1},e={x:1,y:1,z:1},n={x:0,y:0,z:0},r=null,a=null,s=new _.utils.ListenerHandler,h=!1;function u(){f()}function l(){var e=document.createElement("div");return e.id=_.gui.getLayerDivId(S.getDivId(),m.length),e.className="layer",e.style.pointerEvents="none",e}function f(e){void 0===e&&(e=x),c();var t=m[0],e=t.getViewController().getPlanePositionFromPosition(e),t=t.planePosToDisplay(e.x,e.y),e=document.createElement("hr"),n=(e.id=S.getDivId()+"-scroll-crosshair-horizontal",e.className="horizontal",e.style.width=o.offsetWidth+"px",e.style.left="0px",e.style.top=t.y+"px",document.createElement("hr"));n.id=S.getDivId()+"-scroll-crosshair-vertical",n.className="vertical",n.style.width=o.offsetHeight+"px",n.style.left=t.x+"px",n.style.top="0px",o.appendChild(e),o.appendChild(n)}function c(){var e=document.getElementById(S.getDivId()+"-scroll-crosshair-horizontal");e&&e.remove(),(e=document.getElementById(S.getDivId()+"-scroll-crosshair-vertical"))&&e.remove()}function p(e){s.fireEvent(e)}this.getTargetOrientation=function(){return t},this.setTargetOrientation=function(e){t=e},this.getShowCrosshair=function(){return h},this.setShowCrosshair=function(e){(h=e)?(S.addEventListener("offsetchange",u),S.addEventListener("zoomchange",u),f()):(S.removeEventListener("offsetchange",u),S.removeEventListener("zoomchange",u),c())},this.getDivId=function(){return o.id},this.getScale=function(){return i},this.getBaseScale=function(){return e},this.getAddedScale=function(){return{x:i.x/e.x,y:i.y/e.y,z:i.z/e.z}},this.getOffset=function(){return n},this.getNumberOfLayers=function(){return m.length},this.getActiveViewLayer=function(){return m[r]},this.getViewLayersByDataIndex=function(e){for(var t=[],n=0;n<m.length;++n)m[n]instanceof _.gui.ViewLayer&&m[n].getDataIndex()===e&&t.push(m[n]);return t},this.searchViewLayers=function(e){for(var t=[],n=0;n<m.length;++n)m[n]instanceof _.gui.ViewLayer&&m[n].getViewController().equalImageMeta(e)&&t.push(m[n]);return t},this.getViewDataIndices=function(){for(var e=[],t=0;t<m.length;++t)m[t]instanceof _.gui.ViewLayer&&e.push(m[t].getDataIndex());return e},this.getActiveDrawLayer=function(){return m[a]},this.getDrawLayersByDataIndex=function(e){for(var t=[],n=0;n<m.length;++n)m[n]instanceof _.gui.DrawLayer&&m[n].getDataIndex()===e&&t.push(m[n]);return t},this.setActiveViewLayer=function(e){r=e},this.setActiveViewLayerByDataIndex=function(e){for(var t=0;t<m.length;++t)if(m[t]instanceof _.gui.ViewLayer&&m[t].getDataIndex()===e){this.setActiveViewLayer(t);break}},this.setActiveDrawLayer=function(e){a=e},this.setActiveDrawLayerByDataIndex=function(e){for(var t=0;t<m.length;++t)if(m[t]instanceof _.gui.DrawLayer&&m[t].getDataIndex()===e){this.setActiveDrawLayer(t);break}},this.addViewLayer=function(){var e=m.length,t=l(),t=(o.append(t),new _.gui.ViewLayer(t)),n=(m.push(t),this.setActiveViewLayer(e),t);n.addEventListener("positionchange",S.updateLayersToPositionChange);for(var i=0;i<_.image.viewEventNames.length;++i)n.addEventListener(_.image.viewEventNames[i],p);return n.addEventListener("renderstart",p),n.addEventListener("renderend",p),t},this.addDrawLayer=function(){a=m.length;var e,t=l(),t=(o.append(t),new _.gui.DrawLayer(t));return m.push(t),(e=t).addEventListener("drawcreate",p),e.addEventListener("drawdelete",p),t},this.empty=function(){m=[],a=r=null;var e=o.getElementsByClassName("layer");if(e)for(;0<e.length;)e[0].remove()},this.updateLayersToPositionChange=function(e){for(var t=0;t<m.length;++t)m[t]instanceof _.gui.ViewLayer&&(m[t].removeEventListener("positionchange",S.updateLayersToPositionChange),m[t].removeEventListener("positionchange",p));for(var n=new _.math.Index(e.value[0]),i=new _.math.Point(e.value[1]),r=(x=i,h&&f(i),null),o=null,a=0;a<m.length;++a){var s,u,l,c=!1,d=(m[a]instanceof _.gui.ViewLayer&&(s=(d=m[a].getViewController()).getOrigin(),u=d.getOrigin(i),o?d.canSetPosition(i)&&void 0!==u&&(d=r.minus(s),d=new _.math.Vector3D(d.getX(),d.getY(),d.getZ()),l=o.minus(u),l=new _.math.Vector3D(l.getX(),l.getY(),l.getZ()),c=m[a].setBaseOffset(d,l)):(r=s,o=u)),!1);!(d=m[a].getId()!==e.srclayerid?m[a].setCurrentPosition(i,n):d)&&c&&m[a].draw()}for(var g=0;g<m.length;++g)m[g]instanceof _.gui.ViewLayer&&(m[g].addEventListener("positionchange",S.updateLayersToPositionChange),m[g].addEventListener("positionchange",p))},this.calculateFitScale=function(){if(0===o.offsetWidth&&0===o.offsetHeight)throw new Error("Cannot fit to zero sized container.");var e=this.getMaxSize();if(void 0!==e)return Math.min(o.offsetWidth/e.x,o.offsetHeight/e.y)},this.setFitScale=function(e){var t=this.getMaxSize();if(void 0!==t){for(var n={x:o.offsetWidth,y:o.offsetHeight},i={x:-.5*(n.x-Math.floor(t.x*e)),y:-.5*(n.y-Math.floor(t.y*e))},r=0;r<m.length;++r)m[r].fitToContainer(e,n,i);h&&f()}},this.getMaxSize=function(){for(var e,t={x:0,y:0},n=0;n<m.length;++n)m[n]instanceof _.gui.ViewLayer&&((e=m[n].getImageWorldSize()).x>t.x&&(t.x=e.x),e.y>t.y&&(t.y=e.y));return t=0===t.x&&0===t.y?void 0:t},this.flipScaleZ=function(){e.z*=-1,this.setScale(e)},this.addScale=function(e,t){e={x:i.x*(1+e),y:i.y*(1+e),z:i.z*(1+e)};this.setScale(e,t)},this.setScale=function(e,t){i=e;for(var n=0;n<m.length;++n)m[n].setScale(i,t);e=[e.x,e.y,e.z];void 0!==t&&(e.push(t.getX()),e.push(t.getY()),e.push(t.getZ())),p({type:"zoomchange",value:e})},this.addTranslation=function(e){this.setOffset({x:n.x-e.x,y:n.y-e.y,z:n.z-e.z})},this.setOffset=function(e){n=e;for(var t=0;t<m.length;++t)m[t].setOffset(n);p({type:"offsetchange",value:[n.x,n.y,n.z]})},this.reset=function(){this.setScale(e),this.setOffset({x:0,y:0,z:0})},this.draw=function(){for(var e=0;e<m.length;++e)m[e].draw()},this.display=function(e){for(var t=0;t<m.length;++t)m[t].display(e)},this.addEventListener=function(e,t){s.add(e,t)},this.removeEventListener=function(e,t){s.remove(e,t)}},_||{}),_=(_.gui=_.gui||{},_.gui.WindowLevelBinder=function(){this.getEventType=function(){return"wlchange"},this.getCallback=function(n){return function(e){var t=n.getViewLayersByDataIndex(e.dataid);0!==t.length&&t[0].getViewController().setWindowLevel(e.value[0],e.value[1])}}},_.gui.PositionBinder=function(){this.getEventType=function(){return"positionchange"},this.getCallback=function(o){return function(e){var e=e.value[1],t=o.getActiveViewLayer().getViewController(),n=t.getCurrentPosition(),i=n.length(),r=e.length;r!==i&&(r===i-1?e.push(n.get(i-1)):r===i+1&&e.pop()),t.setCurrentPosition(new _.math.Point(e))}}},_.gui.ZoomBinder=function(){this.getEventType=function(){return"zoomchange"},this.getCallback=function(i){return function(e){var t,n={x:e.value[0],y:e.value[1],z:e.value[2]};6===e.value.length&&(t=new _.math.Point3D(e.value[3],e.value[4],e.value[5])),i.setScale(n,t),i.draw()}}},_.gui.OffsetBinder=function(){this.getEventType=function(){return"offsetchange"},this.getCallback=function(t){return function(e){t.setOffset({x:e.value[0],y:e.value[1],z:e.value[2]}),t.draw()}}},_.gui.OpacityBinder=function(){this.getEventType=function(){return"opacitychange"},this.getCallback=function(n){return function(e){var t;void 0!==e.dataid&&0!==(t=n.getViewLayersByDataIndex(e.dataid)).length&&(t[0].setOpacity(e.value),t[0].draw())}}},_.gui.Stage=function(){var o=[],n=null,i=[],r=null;function a(t,n){void 0===r[n]&&(r[n]=[]);var e=r[n].find(function(e){return e.binder===t});return void 0===e&&r[n].push(e={binder:t,callback:function(e){u(n,t),t.getCallback(o[n])(e),s(n,t)}}),e.callback}function s(e,t){for(var n=0;n<o.length;++n)n!==e&&o[e].addEventListener(t.getEventType(),a(t,n))}function u(e,t){for(var n=0;n<o.length;++n)n!==e&&o[e].removeEventListener(t.getEventType(),a(t,n))}this.getLayerGroup=function(e){return o[e]},this.getNumberOfLayerGroups=function(){return o.length},this.getActiveLayerGroup=function(){return this.getLayerGroup(n)},this.getViewLayersByDataIndex=function(e){for(var t=[],n=0;n<o.length;++n)t=t.concat(o[n].getViewLayersByDataIndex(e));return t},this.getDrawLayersByDataIndex=function(e){for(var t=[],n=0;n<o.length;++n)t=t.concat(o[n].getDrawLayersByDataIndex(e));return t},this.addLayerGroup=function(e){n=o.length;var e=new _.gui.LayerGroup(e),t=r&&0!==r.length;return t&&this.unbindLayerGroups(),o.push(e),t&&this.bindLayerGroups(),e},this.getLayerGroupByDivId=function(t){return o.find(function(e){return e.getDivId()===t})},this.setBinders=function(e){if(null==e)throw new Error("Cannot set null or undefined binders");0!==i.length&&this.unbindLayerGroups(),i=e.slice(),this.bindLayerGroups()},this.empty=function(){this.unbindLayerGroups();for(var e=0;e<o.length;++e)o[e].empty();o=[],n=null},this.reset=function(){for(var e=0;e<o.length;++e)o[e].reset()},this.draw=function(){for(var e=0;e<o.length;++e)o[e].draw()},this.syncLayerGroupScale=function(){for(var e,t=[],n=0;n<o.length;++n){var i=o[n].calculateFitScale();void 0!==i&&(t.push(n),(void 0===e||i<e)&&(e=i))}if(void 0!==e)for(var r=0;r<o.length;++r)t.includes(r)&&o[r].setFitScale(e)},this.bindLayerGroups=function(){if(0!==o.length&&1!==o.length&&0!==i.length){r=new Array(o.length);for(var e=0;e<o.length;++e)for(var t=0;t<i.length;++t)s(e,i[t])}},this.unbindLayerGroups=function(){if(0!==o.length&&1!==o.length&&0!==i.length&&r){for(var e=0;e<o.length;++e)for(var t=0;t<i.length;++t)u(e,i[t]);r=null}}},_||{}),_=(_.gui=_.gui||{},_.gui.Style=function(){var t="#ffff80",n={x:1,y:1},i={x:1,y:1},e={x:.25,y:.25};this.getFontFamily=function(){return"Verdana"},this.getFontSize=function(){return 10},this.getStrokeWidth=function(){return 2},this.getTextColour=function(){return"#fff"},this.getLineColour=function(){return t},this.setLineColour=function(e){t=e},this.setBaseScale=function(e){n=e},this.setZoomScale=function(e){i=e},this.getBaseScale=function(){return n},this.getZoomScale=function(){return i},this.scale=function(e){return e/n.x},this.applyZoomScale=function(e){return{x:2*e/i.x,y:2*e/i.y}},this.getShadowOffset=function(){return e},this.getTagOpacity=function(){return.2},this.getTextPadding=function(){return 3}},_.gui.Style.prototype.getFontStr=function(){return"normal "+this.getFontSize()+"px sans-serif"},_.gui.Style.prototype.getLineHeight=function(){return this.getFontSize()+this.getFontSize()/5},_.gui.Style.prototype.getScaledFontSize=function(){return this.scale(this.getFontSize())},_.gui.Style.prototype.getScaledStrokeWidth=function(){return this.scale(this.getStrokeWidth())},_.gui.Style.prototype.getShadowLineColour=function(){return _.utils.getShadowColour(this.getLineColour())},_||{}),_=(_.gui=_.gui||{},_.gui.ViewLayer=function(i){i.className+=" viewLayer";var t,s,r=this,o=null,u=null,a=null,l=null,c=!0,n=null,d=1,g={x:1,y:1},x={x:1,y:1},S={x:0,y:0},m={x:0,y:0},h={x:0,y:0},f={x:0,y:0},p={x:0,y:0},y=null,D=null,v=(this.getDataIndex=function(){return D},new _.utils.ListenerHandler),C=!1;function T(e){if(!_.gui.canCreateCanvas(e.x,e.y))throw new Error("Cannot create canvas with size "+e.x+", "+e.y);t=e,a.width=t.x,a.height=t.y,l.clearRect(0,0,t.x,t.y),n=l.createImageData(t.x,t.y)}function L(e){e.srclayerid=r.getId(),e.dataid=D,v.fireEvent(e)}function I(e){void 0!==e.skipGenerate&&!0===e.skipGenerate||(y=!0,r.draw())}function P(e){void 0!==event.skipGenerate&&!0===event.skipGenerate||(y=!0,r.draw())}function w(e){var t,n;void 0!==e.skipGenerate&&!0===e.skipGenerate||(n=!0,(n=void 0!==e.valid?e.valid:n)?(n=(t=[0,1,2]).indexOf(o.getScrollIndex()),t.splice(n,1),0===e.diffDims.filter(function(e){return-1===t.indexOf(e)}).length&&c||(y=c=!0,r.draw())):c&&(c=!1,r.clear()))}function A(e){void 0!==e.skipGenerate&&!0===e.skipGenerate||(y=!0,r.draw())}this.enableImageSmoothing=function(e){C=e},this.setView=function(e,t){D=t,e.addEventListener("wlchange",I),e.addEventListener("colourchange",P),e.addEventListener("positionchange",w),e.addEventListener("alphafuncchange",A);for(var n=0;n<_.image.viewEventNames.length;++n)e.addEventListener(_.image.viewEventNames[n],L);o=new _.ctrl.ViewController(e,t)},this.getViewController=function(){return o},this.getImageData=function(){return n},this.onimageset=function(e){D===e.dataid&&(o.setImage(e.value[0],D),T(o.getImageSize().get2D()),y=!0)},this.onimagechange=function(e){D===e.dataid&&(y=!0)},this.getId=function(){return i.id},this.getBaseSize=function(){return t},this.getImageWorldSize=function(){return o.getImageWorldSize()},this.getOpacity=function(){return d},this.setOpacity=function(e){e!==d&&L({type:"opacitychange",value:[d=Math.min(Math.max(e,0),1)]})},this.addFlipOffsetX=function(){p.x+=u.width/g.x,S.x+=p.x},this.addFlipOffsetY=function(){p.y+=u.height/g.y,S.y+=p.y},this.setScale=function(e,t){var n=o.getPlaneHelper(),i=n.getTargetOrientedPositiveXYZ(e),i={x:x.x*i.x,y:x.y*i.y};1===Math.abs(e.x)&&1===Math.abs(e.y)&&1===Math.abs(e.z)?(e={x:S.x-f.x,y:S.y-f.y},f={x:0,y:0},S=e):void 0!==t&&(e={x:(e=n.getPlaneOffsetFromOffset3D({x:t.getX(),y:t.getY(),z:t.getZ()})).x+m.x,y:e.y+m.y},n=_.gui.getScaledOffset(S,g,i,e),t={x:f.x+n.x-S.x,y:f.y+n.y-S.y},f=t,S=n),g=i},this.setBaseOffset=function(e,t){var n=o.getPlaneHelper(),i=n.getNativeScrollIndex(),n=n.getPlaneOffsetFromOffset3D({x:(0===i?e:t).getX(),y:(1===i?e:t).getY(),z:(2===i?e:t).getZ()}),i=m.x!==n.x||m.y!==n.y;return i&&(S={x:S.x-m.x+n.x,y:S.y-m.y+n.y},m=n),i},this.setOffset=function(e){e=o.getPlaneHelper().getPlaneOffsetFromOffset3D(e);S={x:e.x+h.x+m.x+f.x+p.x,y:e.y+h.y+m.y+f.y+p.y}},this.displayToPlaneIndex=function(e,t){e=this.displayToPlanePos(e,t);return new _.math.Index([Math.floor(e.x),Math.floor(e.y)])},this.displayToPlaneScale=function(e,t){return{x:e/g.x,y:t/g.y}},this.displayToPlanePos=function(e,t){e=this.displayToPlaneScale(e,t);return{x:e.x+S.x,y:e.y+S.y}},this.planePosToDisplay=function(e,t){return{x:(e-S.x+m.x)*g.x,y:(t-S.y+m.y)*g.y}},this.displayToMainPlanePos=function(e,t){e=this.displayToPlanePos(e,t);return{x:e.x-m.x,y:e.y-m.y}},this.display=function(e){i.style.display=e?"":"none"},this.isVisible=function(){return""===i.style.display},this.draw=function(){c&&(L({type:"renderstart",layerid:this.getId(),dataid:this.getDataIndex()}),y&&(o.generateImageData(n),a.getContext("2d").putImageData(n,0,0),y=!1),l.globalAlpha=d,this.clear(),l.setTransform(g.x,0,0,g.y,-1*S.x*g.x,-1*S.y*g.y),l.imageSmoothingEnabled=C,l.drawImage(a,0,0),L({type:"renderend",layerid:this.getId(),dataid:this.getDataIndex()}))},this.initialise=function(e,t,n){s=t,d=Math.min(Math.max(n,0),1),u=document.createElement("canvas"),i.appendChild(u),u.getContext?(l=u.getContext("2d"))?(a=document.createElement("canvas"),T(e),y=!0):alert("Error: failed to get the 2D context."):alert("Error: no canvas.getContext method.")},this.fitToContainer=function(e,t,n){var i=!1;if(u.width!==t.x||u.height!==t.y){if(!_.gui.canCreateCanvas(t.x,t.y))throw new Error("Cannot resize canvas "+t.x+", "+t.y);u.width=t.x,u.height=t.y,i=!0}var t=x,r=g.x/x.x,o=g.y/x.y,e={x:e*s.x,y:e*s.y},a={x:r*e.x,y:o*e.y},r=(r===a.x&&o===a.y||(x=e,g=a,i=!0),{x:n.x/e.x,y:n.y/e.y}),o={x:p.x*t.x/e.x,y:p.y*t.y/e.y};h.x===r.x&&h.y===r.y&&p.x===o.x&&p.y===o.y||(p=o,S={x:(h=r).x+m.x+f.x+p.x,y:h.y+m.y+f.y+p.y},i=!0),i&&this.draw()},this.bindInteraction=function(){i.style.pointerEvents="auto";for(var e=_.gui.interactionEventNames,t=0;t<e.length;++t)i.addEventListener(e[t],L,{passive:!0})},this.unbindInteraction=function(){i.style.pointerEvents="none";for(var e=_.gui.interactionEventNames,t=0;t<e.length;++t)i.removeEventListener(e[t],L)},this.addEventListener=function(e,t){v.add(e,t)},this.removeEventListener=function(e,t){v.remove(e,t)},this.setCurrentPosition=function(e,t){return o.setCurrentPosition(e)},this.clear=function(){l.save(),l.setTransform(1,0,0,1,0,0),l.clearRect(0,0,u.width,u.height),l.restore()},this.align=function(e){u.style.top=e.getCanvas().offsetTop,u.style.left=e.getCanvas().offsetLeft}},_||{}),c=(_.image=_.image||{},"undefined"!=typeof JpegImage),d="undefined"!=typeof jpeg&&void 0!==jpeg.lossless,g="undefined"!=typeof JpxImage,_=(_.image.AsynchPixelBufferDecoder=function(i,e){var r=new _.utils.ThreadPool(10),o=!1,a=this;this.decode=function(e,t,n){o||(o=!0,r.onworkstart=a.ondecodestart,r.onworkitem=a.ondecodeditem,r.onwork=a.ondecoded,r.onworkend=a.ondecodeend,r.onerror=a.onerror,r.onabort=a.onabort);e=new _.utils.WorkerTask(i,{buffer:e,meta:t},n);r.addWorkerTask(e)},this.abort=function(){r.abort()}},_.image.AsynchPixelBufferDecoder.prototype.ondecodestart=function(e){},_.image.AsynchPixelBufferDecoder.prototype.ondecodeditem=function(e){},_.image.AsynchPixelBufferDecoder.prototype.ondecoded=function(e){},_.image.AsynchPixelBufferDecoder.prototype.ondecodeend=function(e){},_.image.AsynchPixelBufferDecoder.prototype.onerror=function(e){},_.image.AsynchPixelBufferDecoder.prototype.onabort=function(e){},_.image.SynchPixelBufferDecoder=function(s,u){var l=0;this.decode=function(e,t,n){++l;var i=null,r=null;if("jpeg-lossless"===s){if(!d)throw new Error("No JPEG Lossless decoder provided");var o=t.bitsAllocated/8,a=new Uint8Array(e),a=(i=new jpeg.lossless.Decoder).decode(a.buffer,0,a.buffer.byteLength,o);8===t.bitsAllocated?r=new(t.isSigned?Int8Array:Uint8Array)(a.buffer):16===t.bitsAllocated&&(r=new(t.isSigned?Int16Array:Uint16Array)(a.buffer))}else if("jpeg-baseline"===s){if(!c)throw new Error("No JPEG Baseline decoder provided");(i=new JpegImage).parse(e),r=i.getData(i.width,i.height)}else if("jpeg2000"===s){if(!g)throw new Error("No JPEG 2000 decoder provided");(i=new JpxImage).parse(e),r=i.tiles[0].items}else"rle"===s&&(r=(i=new _.decoder.RleDecoder).decode(e,t.bitsAllocated,t.isSigned,t.sliceSize,t.samplesPerPixel,t.planarConfiguration));this.ondecodeditem({data:[r],index:n.itemNumber}),l===u&&(this.ondecoded({}),this.ondecodeend({}))},this.abort=function(){this.onabort({}),this.ondecodeend({})}},_.image.SynchPixelBufferDecoder.prototype.ondecodestart=function(e){},_.image.SynchPixelBufferDecoder.prototype.ondecodeditem=function(e){},_.image.SynchPixelBufferDecoder.prototype.ondecoded=function(e){},_.image.SynchPixelBufferDecoder.prototype.ondecodeend=function(e){},_.image.SynchPixelBufferDecoder.prototype.onerror=function(e){},_.image.SynchPixelBufferDecoder.prototype.onabort=function(e){},_.image.PixelBufferDecoder=function(e,t){var i=null,i=void 0!==_.image.decoderScripts&&void 0!==_.image.decoderScripts[e]?new _.image.AsynchPixelBufferDecoder(_.image.decoderScripts[e],t):new _.image.SynchPixelBufferDecoder(e,t),r=!1;this.decode=function(e,t,n){r||(r=!0,i.ondecodestart=this.ondecodestart,i.ondecodeditem=this.ondecodeditem,i.ondecoded=this.ondecoded,i.ondecodeend=this.ondecodeend,i.onerror=this.onerror,i.onabort=this.onabort),i.decode(e,t,n)},this.abort=function(){i.abort()}},_.image.PixelBufferDecoder.prototype.ondecodestart=function(e){},_.image.PixelBufferDecoder.prototype.ondecodeditem=function(e){},_.image.PixelBufferDecoder.prototype.ondecoded=function(e){},_.image.PixelBufferDecoder.prototype.ondecodeend=function(e){},_.image.PixelBufferDecoder.prototype.onerror=function(e){},_.image.PixelBufferDecoder.prototype.onabort=function(e){},_||{}),_=(_.image=_.image||{},_.image.DicomBufferToView=function(){var c,d=this,g=(this.setOptions=function(e){c=e},null),x=[],S=[],m=[];function h(e,t){var n=x[e].getDicomElements(),i=_.dicom.cleanString(n.getFromKey("x00080060")),i=new(i&&"SEG"===i?_.image.MaskFactory:_.image.ImageFactory);try{var r=i.create(n,S[e],c.numberOfFiles);d.onloaditem({data:{image:r,info:x[e].getRawDicomElements()},source:t})}catch(e){d.onerror({error:e,source:t}),d.onloadend({source:t})}}this.convert=function(e,t,n){d.onloadstart({source:t,dataIndex:n});var i=new _.dicom.DicomParser,r=new _.ImageFactory;void 0!==c.defaultCharacterSet&&i.setDefaultCharacterSet(c.defaultCharacterSet);try{i.parse(e),r.checkElements(i.getDicomElements())}catch(e){return d.onerror({error:e,source:t}),void d.onloadend({source:t})}var o=i.getRawDicomElements().x7FE00010.value,e=(i.getRawDicomElements().x7FE00010.value=[],_.dicom.cleanString(i.getRawDicomElements().x00020010.value[0])),r=_.dicom.getSyntaxDecompressionName(e),e=null!==r;if(x[n]=i,S[n]=o[0],e){var a={bitsAllocated:i.getRawDicomElements().x00280100.value[0],isSigned:1===i.getRawDicomElements().x00280103.value[0]},e=i.getRawDicomElements().x00280011,s=i.getRawDicomElements().x00280010,e=(void 0!==e&&void 0!==s&&(a.sliceSize=e.value[0]*s.value[0]),i.getRawDicomElements().x00280002),s=(void 0!==e&&(a.samplesPerPixel=e.value[0]),i.getRawDicomElements().x00280006),u=(void 0!==s&&(a.planarConfiguration=s.value[0]),o.length);null===g&&((g=new _.image.PixelBufferDecoder(r,u)).ondecodeditem=function(e){!function(e){d.onprogress({lengthComputable:!0,loaded:e.itemNumber+1,total:e.numberOfItems,index:e.dataIndex,source:origin});var t=e.dataIndex,n=e.data[0];if(1!==e.numberOfItems){if(void 0===m[t]){m[t]=n.length;var i,r=e.numberOfItems*m[t];try{S[t]=new n.constructor(r)}catch(e){return e instanceof RangeError&&(i=Math.floor(Math.log(r)/Math.log(2)),_.logger.error("Cannot allocate "+n.constructor.name+" of size: "+r+" (>2^"+i+") for decompressed data.")),g.abort(),d.onerror({error:e,source:origin}),d.onloadend({source:origin})}}n.length!==m[t]&&_.logger.warn("Unsupported varying decompressed data size: "+n.length+" != "+m[t]),S[t].set(n,m[t]*e.itemNumber)}else S[t]=n;0===e.itemNumber&&h(t,origin)}(e),e.itemNumber+1===e.numberOfItems&&(d.onload(e),d.onloadend(e))},g.onerror=d.onerror,g.onabort=d.onabort);for(var l=0;l<u;++l)g.decode(o[l],a,{itemNumber:l,numberOfItems:u,dataIndex:n})}else d.onprogress({lengthComputable:!0,loaded:100,total:100,index:n,source:t}),h(n,t),d.onload({source:t}),d.onloadend({source:t})},this.abort=function(){g&&g.abort()}},_.image.DicomBufferToView.prototype.onloadstart=function(e){},_.image.DicomBufferToView.prototype.onloaditem=function(e){},_.image.DicomBufferToView.prototype.onprogress=function(e){},_.image.DicomBufferToView.prototype.onload=function(e){},_.image.DicomBufferToView.prototype.onloadend=function(e){},_.image.DicomBufferToView.prototype.onerror=function(e){},_.image.DicomBufferToView.prototype.onabort=function(e){},_||{}),_=(_.image=_.image||{},_.image.imageDataToBuffer=function(e){for(var t=e.data.length,n=new Uint8Array(t/4*3),i=0,r=0;r<t;r+=4)n[i]=e.data[r],n[i+1]=e.data[r+1],n[i+2]=e.data[r+2],i+=3;return n},_.image.getDefaultImage=function(e,t,n,i,r,o){e=new _.image.Size([e,t,1]),t=new _.image.Spacing([1,1,1]),n=new _.math.Point3D(0,0,n),n=new _.image.Geometry(n,e,t),e=new _.image.Image(n,i,[o]),e.setPhotometricInterpretation("RGB"),t={};return t.BitsStored=8,void 0!==r&&(t.numberOfFiles=r),e.setMeta(t),e},_.image.getViewFromDOMImage=function(e,t){var n=e.width,i=e.height,r=document.createElement("canvas"),r=(r.width=n,r.height=i,r.getContext("2d")),r=(r.drawImage(e,0,0),r.getImageData(0,0,n,i)),o={},e=("string"==typeof e.origin?o.origin={value:e.origin}:(o.fileName={value:e.origin.name},o.fileType={value:e.origin.type},o.fileLastModifiedDate={value:e.origin.lastModifiedDate}),o.imageWidth={value:n},o.imageHeight={value:i},e.index||0),r=(o.imageUid={value:e},_.image.imageDataToBuffer(r));return{data:{image:_.image.getDefaultImage(n,i,e,r,1,e),info:o},source:t}},_.image.getViewFromDOMVideo=function(t,n,i,r,o,a,s){var u=t.videoWidth,l=t.videoHeight,c=Math.ceil(30*t.duration),d={},e=(t.file&&(d.fileName={value:t.file.name},d.fileType={value:t.file.type},d.fileLastModifiedDate={value:t.file.lastModifiedDate}),d.imageWidth={value:u},d.imageHeight={value:l},d.numberOfFrames={value:c},d.imageUid={value:0},document.createElement("canvas")),g=(e.width=u,e.height=l,e.getContext("2d")),x=(t.addEventListener("seeked",function e(){m();h+=1/30;h<=this.duration?this.currentTime=h:(i({source:s}),o({source:s}),t.removeEventListener("seeked",e))},!1),0),S=null;function m(){r({lengthComputable:!0,loaded:x,total:c,index:a,source:s}),g.drawImage(t,0,0);var e=_.image.imageDataToBuffer(g.getImageData(0,0,u,l));0===x?(S=_.image.getDefaultImage(u,l,1,e,c,a),n({data:{image:S,info:d},source:s})):S.appendFrameBuffer(e,x),++x}var h=0;t.currentTime=h},_||{}),_=(_.image=_.image||{},_.image.filter=_.image.filter||{},_.image.filter.Threshold=function(){var t=0,n=0,i=(this.getMin=function(){return t},this.setMin=function(e){t=e},this.getMax=function(){return n},this.setMax=function(e){n=e},this.getName=function(){return"Threshold"},null);this.setOriginalImage=function(e){i=e},this.getOriginalImage=function(){return i}},_.image.filter.Threshold.prototype.update=function(){var e=this.getOriginalImage(),t=e.getDataRange().min,n=this;return e.transform(function(e){return e<n.getMin()||e>n.getMax()?t:e})},_.image.filter.Sharpen=function(){this.getName=function(){return"Sharpen"};var t=null;this.setOriginalImage=function(e){t=e},this.getOriginalImage=function(){return t}},_.image.filter.Sharpen.prototype.update=function(){return this.getOriginalImage().convolute2D([0,-1,0,-1,5,-1,0,-1,0])},_.image.filter.Sobel=function(){this.getName=function(){return"Sobel"};var t=null;this.setOriginalImage=function(e){t=e},this.getOriginalImage=function(){return t}},_.image.filter.Sobel.prototype.update=function(){var e=this.getOriginalImage(),t=e.convolute2D([1,0,-1,2,0,-2,1,0,-1]),e=e.convolute2D([1,2,1,0,0,0,-1,-2,-1]);return t.compose(e,function(e,t){return Math.sqrt(e*e+t*t)})},_||{}),_=(_.image=_.image||{},_.image.Geometry=function(e,i,r,s,t){var o,u=[e],l={},a=(void 0!==t&&(l[o=t]=[e]),void 0===s&&(s=new _.math.getIdentityMat33),!1);this.getInitialTime=function(){return o},this.getCurrentTotalNumberOfSlices=function(){var e=Object.keys(l);if(0===e.length)return u.length;for(var t=0,n=0;n<e.length;++n)t+=l[e[n]].length;return t},this.hasSlicesAtTime=function(e){return void 0!==l[e]},this.getCurrentNumberOfSlicesBeforeTime=function(e){var t=Object.keys(l);if(0!==t.length){for(var n=0,i=0;i<t.length;++i){var r=t[i];if(parseInt(r,10)===e)break;n+=l[r].length}return n}},this.getOrigin=function(){return u[0]},this.getOrigins=function(){return u},this.includesOrigin=function(e,t){for(var n=0;n<u.length;++n)if(u[n].isSimilar(e,t))return!0;return!1},this.getSize=function(e){var t=i;return e&&void 0!==e&&(e=(e=_.image.getOrientedArray3D([i.get(0),i.get(1),i.get(2)],e)).map(Math.abs),t=new _.image.Size(e.concat(i.getValues().slice(3)))),t},this.getSpacing=function(e){a&&(void 0!==(n=_.image.getSliceGeometrySpacing(u,s))&&r.get(2)!==n&&(_.logger.trace("Updating slice spacing."),(t=r.getValues())[2]=n,r=new _.image.Spacing(t)),a=!1);var t,n=r;return e&&void 0!==e&&(t=(t=_.image.getOrientedArray3D([r.get(0),r.get(1),r.get(2)],e)).map(Math.abs),n=new _.image.Spacing(t)),n},this.getRealSpacing=function(){return this.getSpacing(s.getInverse().asOneAndZeros())},this.getOrientation=function(){return s},this.getSliceIndex=function(e,t){for(var n,i=u,r=(void 0!==t&&(i=l[t]),0),o=e.getDistance(i[0]),a=0;a<i.length;++a)(n=e.getDistance(i[a]))<o&&(o=n,r=a);t=i[r],t=e.minus(t);return 0<new _.math.Vector3D(s.get(0,2),s.get(1,2),s.get(2,2)).dotProduct(t)?r+1:r},this.appendOrigin=function(e,t,n){void 0!==n&&l[n].splice(t,0,e),void 0!==n&&n!==o||(a=!0,u.splice(t,0,e),(n=i.getValues())[2]+=1,i=new _.image.Size(n))},this.appendFrame=function(e,t){l[t]=[e];t=i.getValues(),e=r.getValues();4===t.length?t[3]+=1:(t.push(2),e.push(1)),i=new _.image.Size(t),r=new _.image.Spacing(e)}},_.image.Geometry.prototype.toString=function(){return"Origin: "+this.getOrigin()+", Size: "+this.getSize()+", Spacing: "+this.getSpacing()+", Orientation: "+this.getOrientation()},_.image.Geometry.prototype.equals=function(e){return null!==e&&this.getOrigin().equals(e.getOrigin())&&this.getSize().equals(e.getSize())&&this.getSpacing().equals(e.getSpacing())},_.image.Geometry.prototype.isInBounds=function(e){return this.isIndexInBounds(this.worldToIndex(e))},_.image.Geometry.prototype.isIndexInBounds=function(e,t){return this.getSize().isInBounds(e,t)},_.image.Geometry.prototype.indexToWorld=function(e){var t=this.getSpacing(),t=new _.math.Point3D(e.get(0)*t.get(0),e.get(1)*t.get(1),e.get(2)*t.get(2)),t=this.getOrientation().multiplyPoint3D(t),e=e.getValues(),n=this.getOrigin();return e[0]=n.getX()+t.getX(),e[1]=n.getY()+t.getY(),e[2]=n.getZ()+t.getZ(),new _.math.Point(e)},_.image.Geometry.prototype.pointToWorld=function(e){var t=this.getSpacing(),e=new _.math.Point3D(e.getX()*t.get(0),e.getY()*t.get(1),e.getZ()*t.get(2)),t=this.getOrientation().multiplyPoint3D(e),e=this.getOrigin();return new _.math.Point3D(e.getX()+t.getX(),e.getY()+t.getY(),e.getZ()+t.getZ())},_.image.Geometry.prototype.worldToIndex=function(e){var t=this.getOrigin(),t=new _.math.Point3D(e.get(0)-t.getX(),e.get(1)-t.getY(),e.get(2)-t.getZ()),t=this.getOrientation().getInverse().multiplyPoint3D(t),e=e.getValues(),n=this.getSpacing();return e[0]=Math.round(t.getX()/n.get(0)),e[1]=Math.round(t.getY()/n.get(1)),e[2]=Math.round(t.getZ()/n.get(2)),new _.math.Index(e)},_.image.Geometry.prototype.worldToPoint=function(e){var t=this.getOrigin(),t=new _.math.Point3D(e.get(0)-t.getX(),e.get(1)-t.getY(),e.get(2)-t.getZ()),t=this.getOrientation().getInverse().multiplyPoint3D(t),e=e.getValues(),n=this.getSpacing();return e[0]=t.getX()/n.get(0),e[1]=t.getY()/n.get(1),e[2]=t.getZ()/n.get(2),new _.math.Point3D(e[0],e[1],e[2])},_.image.getOrientedArray3D=function(e,t){return t.getInverse().multiplyArray3D(e)},_.image.getDeOrientedArray3D=function(e,t){return t.multiplyArray3D(e)},_.image.getSliceGeometrySpacing=function(e,t,n){if(void 0===n&&(n=!0),!(e.length<=1)){for(var i=t.getInverse(),r=i.multiplyVector3D(e[0]),o=i.multiplyVector3D(e[1]),a=Math.abs(r.getZ()-o.getZ()),s=[],u=0;u<e.length-1;++u){var r=i.multiplyVector3D(e[u]),o=i.multiplyVector3D(e[u+1]),l=Math.abs(r.getZ()-o.getZ());if(0===l)throw new Error("Zero slice spacing."+r.toString()+" "+o.toString());l<a&&(a=l),!n||_.math.isSimilar(a,l,_.math.BIG_EPSILON)||s.push(Math.abs(a-l))}return n&&0!==s.length&&(1e-4<(t=s.reduce(function(e,t){return e+t})/s.length)&&_.logger.warn("Varying slice spacing, mean delta: "+t.toFixed(3)+" ("+s.length+" case(s))")),a}},_||{}),_=(_.image=_.image||{},_.image.getSliceIndex=function(e,t){var n=t.getInitialTime(),i=[];return i.push(0),i.push(0),i.push(e.getSliceIndex(t.getOrigin(),n)),void 0!==n&&i.push(n),new _.math.Index(i)},_.image.Image=function(p,y,D){var r=new _.image.RescaleSlopeAndIntercept(1,0),o=null,a=!0,s=!0,v="MONOCHROME2",t=0,C=y.length/p.getSize().getTotalSize(),T={},n=null,i=null,u=null,l=new _.utils.ListenerHandler;function c(){return p.getSize().getTotalSize(2)}function L(e){var t=y;if(null===(y=_.dicom.getTypedArray(8*y.BYTES_PER_ELEMENT,T.IsSigned?1:0,e)))throw new Error("Cannot reallocate data for image.");y.set(t)}function d(e){l.fireEvent(e)}this.getImageUid=function(e){var t=D[0];return t=1!==D.length&&void 0!==e?D[this.getSecondaryOffset(e)]:t},this.getGeometry=function(){return p},this.getBuffer=function(){return y},this.canQuantify=function(){return 1===this.getNumberOfComponents()},this.canWindowLevel=function(){return null!==this.getPhotometricInterpretation().match(/MONOCHROME/)},this.canScroll=function(e){var t=this.getGeometry().getSize(),n=1;return void 0!==T.numberOfFiles&&(n=T.numberOfFiles),t.canScroll(e)||1!==n},this.getSecondaryOffset=function(e){return p.getSize().indexToOffset(e,2)},this.getRescaleSlopeAndIntercept=function(e){var t=r;if(!this.isConstantRSI()){if(void 0===e)throw new Error("Cannot get non constant RSI with empty slice index.");e=this.getSecondaryOffset(e);void 0!==o[e]?t=o[e]:_.logger.warn("undefined non constant rsi at "+e)}return t},this.setRescaleSlopeAndIntercept=function(e,t){if(a=a&&e.isID(),s){if(!r.equals(e))if("undefined"==typeof index)r=e;else{s=!1,o=[];for(var n=0,i=c();n<i;++n)o.push(n);r=null,o.splice(t,0,e)}}else{if("undefined"==typeof index)throw new Error("Cannot store non constant RSI with empty slice index.");o.splice(t,0,e)}},this.isIdentityRSI=function(){return a},this.isConstantRSI=function(){return s},this.getPhotometricInterpretation=function(){return v},this.setPhotometricInterpretation=function(e){v=e},this.getPlanarConfiguration=function(){return t},this.setPlanarConfiguration=function(e){t=e},this.getNumberOfComponents=function(){return C},this.getMeta=function(){return T},this.setMeta=function(e){T=e},this.getValueAtOffset=function(e){return y[e]},this.getOffsets=function(e){1==C?e=[e]:3==C&&void 0!==e.r&&(e=[e.r,e.g,e.b]);for(var t=[],n=0;n<y.length;n+=C){for(var i=!0,r=0;r<C;++r)if(y[n+r]!==e[r]){i=!1;break}i&&t.push(n)}return t},this.hasValues=function(e){if(void 0===e||0===e.length)return[];for(var n,t=[],i=0;i<e.length;++i)1==C?t.push([e[i]]):3==C&&t.push([e[i].r,e[i].g,e[i].b]);1==C?n=function(e,t){return e[0]===t[0]}:3==C&&(n=function(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]});for(var r=new Array(e.length),o=(r.fill(!1),t.slice()),a=0,s=y.length;a<s;a+=C){for(var u=[],l=0;l<o.length;++l){for(var c=!0,d=0;d<C;++d)if(y[a+d]!==o[l][d]){c=!1;break}c&&(r[t.findIndex(function(t){return function(e){return n(e,t)}}(o[l]))]=!0,u.push(l))}for(var g=0;g<u.length;++g)o.splice(u[g],1);if(0===o.length)break}return r},this.clone=function(){var e=y.slice(0),t=new _.image.Image(this.getGeometry(),e,D);if(this.isConstantRSI())t.setRescaleSlopeAndIntercept(this.getRescaleSlopeAndIntercept());else for(var n=0;n<c();++n)t.setRescaleSlopeAndIntercept(o[n],n);return t.setPhotometricInterpretation(this.getPhotometricInterpretation()),t.setPlanarConfiguration(this.getPlanarConfiguration()),t.setMeta(this.getMeta()),t},this.appendSlice=function(e){if(null===e)throw new Error("Cannot append null slice");var t,n=e.getGeometry().getSize(),i=p.getSize();if(1!==n.get(2))throw new Error("Cannot append more than one slice");if(i.get(0)!==n.get(0))throw new Error("Cannot append a slice with different number of columns");if(i.get(1)!==n.get(1))throw new Error("Cannot append a slice with different number of rows");if(!p.getOrientation().equals(e.getGeometry().getOrientation(),1e-4))throw new Error("Cannot append a slice with different orientation");if(v!==e.getPhotometricInterpretation())throw new Error("Cannot append a slice with different photometric interpretation");for(t in T)if("windowPresets"!==t&&"numberOfFiles"!==t&&"custom"!==t&&T[t]!==e.getMeta()[t])throw new Error("Cannot append a slice with different "+t);var n=e.getGeometry().getInitialTime(),r=!1,o=(void 0===n||p.hasSlicesAtTime(n)||(this.appendFrame(e.getGeometry().getOrigin(),n),i=p.getSize(),r=!0),_.image.getSliceIndex(p,e.getGeometry())),i=C*i.getDimSize(2);if(void 0===T.numberOfFiles)throw new Error("Missing number of files for buffer manipulation.");var a=i*T.numberOfFiles,a=(y.length!==a&&L(a),o.get(2)),s=a,o=(void 0!==n&&(s+=p.getCurrentNumberOfSlicesBeforeTime(n)),s*i),u=p.getCurrentTotalNumberOfSlices()*i,l=(o<u&&y.set(y.subarray(o,u),o+i),y.set(e.getBuffer(),o),r||p.appendOrigin(e.getGeometry().getOrigin(),a,n),this.setRescaleSlopeAndIntercept(e.getRescaleSlopeAndIntercept(),s),D.length);if(D.splice(s,0,e.getImageUid()),void 0!==T.windowPresets)for(var c=T.windowPresets,d=e.getMeta().windowPresets,g=Object.keys(d),x=0;x<g.length;++x){var S,m=d[S=g[x]],h=c[S];if(void 0!==h){if((void 0===h.perslice||!1===h.perslice)&&!h.wl[0].equals(m.wl[0])){h.perslice=!0;for(var f=0;f<l-1;++f)h.wl.push(h.wl[0])}void 0!==h.perslice&&!0===h.perslice&&c[S].wl.splice(s,0,m.wl[0])}else c[S]=d[S]}},this.appendFrameBuffer=function(e,t){var n=p.getSize(),n=C*n.getDimSize(2);if(void 0===T.numberOfFiles)throw new Error("Missing number of files for frame buffer manipulation.");var i=n*T.numberOfFiles;if(y.length!==i&&L(i),t>=T.numberOfFiles)throw new Error("Cannot append a frame at an index above the number of frames");y.set(e,n*t),this.appendFrame()},this.appendFrame=function(e,t){p.appendFrame(e,t),d({type:"appendframe"})},this.getDataRange=function(){return n=n||this.calculateDataRange()},this.getRescaledDataRange=function(){return i=i||this.calculateRescaledDataRange()},this.getHistogram=function(){var e;return u||(e=this.calculateHistogram(),n=e.dataRange,i=e.rescaledDataRange,u=e.histogram),u},this.addEventListener=function(e,t){l.add(e,t)},this.removeEventListener=function(e,t){l.remove(e,t)},this.setAtOffsets=function(e,t){for(var n,i=0,r=e.length;i<r;++i)n=e[i],y[n]=t.r,y[n+1]=t.g,y[n+2]=t.b;d({type:"imagechange"})},this.setAtOffsetsAndGetOriginals=function(e,t){for(var n=[],i=0;i<e.length;++i){var r=e[i],o=3*r[0],a={r:y[o],g:y[1+o],b:y[2+o]},s=[];s.push({index:0,colour:a});for(var u=0;u<r.length;++u){var o=3*r[u],l={r:y[o],g:y[1+o],b:y[2+o]};a.r===l.r&&a.g===l.g&&a.b===l.b||(s.push({index:u,colour:l}),a=l),y[o]=t.r,y[1+o]=t.g,y[2+o]=t.b}n.push(s)}return d({type:"imagechange"}),n},this.setAtOffsetsWithIterator=function(e,t){for(var n=0;n<e.length;++n)for(var i=e[n],r=void 0!==t&&void 0!==t.r?new _.image.colourRange([{index:0,colour:t}],i.length):new _.image.colourRange(t[n],i.length),o=r.next();!o.done;){var a=3*i[o.index];y[a]=o.value.r,y[1+a]=o.value.g,y[2+a]=o.value.b,o=r.next()}d({type:"imagechange"})}},_.image.Image.prototype.getValue=function(e,t,n,i){e=new _.math.Index([e,t,n,i||0]);return this.getValueAtOffset(this.getGeometry().getSize().indexToOffset(e))},_.image.Image.prototype.getValueAtIndex=function(e){return this.getValueAtOffset(this.getGeometry().getSize().indexToOffset(e))},_.image.Image.prototype.getRescaledValue=function(e,t,n,i){var r=this.getValue(e,t,n,i=void 0===i?0:i);return r=this.isIdentityRSI()?r:this.isConstantRSI()?this.getRescaleSlopeAndIntercept().apply(r):(e=new _.math.Index([e,t,n,i]),this.getRescaleSlopeAndIntercept(e).apply(r))},_.image.Image.prototype.getRescaledValueAtIndex=function(e){return this.getRescaledValueAtOffset(this.getGeometry().getSize().indexToOffset(e))},_.image.Image.prototype.getRescaledValueAtOffset=function(e){var t=this.getValueAtOffset(e);return t=this.isIdentityRSI()?t:this.isConstantRSI()?this.getRescaleSlopeAndIntercept().apply(t):(e=this.getGeometry().getSize().offsetToIndex(e),this.getRescaleSlopeAndIntercept(e).apply(t))},_.image.Image.prototype.calculateDataRange=function(){var e,t=this.getValueAtOffset(0),n=t,i=this.getGeometry().getSize(),r=i.getTotalSize();3<=i.length()&&(r=i.getDimSize(3));for(var o=0;o<r;++o)n<(e=this.getValueAtOffset(o))&&(n=e),e<t&&(t=e);return{min:t,max:n}},_.image.Image.prototype.calculateRescaledDataRange=function(){if(this.isIdentityRSI())return this.getDataRange();var e;if(this.isConstantRSI())return e=this.getDataRange(),{min:(r=this.getRescaleSlopeAndIntercept().apply(e.min))<(e=this.getRescaleSlopeAndIntercept().apply(e.max))?r:e,max:e<r?r:e};var t,n=this.getRescaledValueAtOffset(0),i=n,r=this.getGeometry().getSize(),o=r.getTotalSize();3===r.length()&&(o=r.getDimSize(3));for(var a=0;a<o;++a)i<(t=this.getRescaledValueAtOffset(a))&&(i=t),t<n&&(n=t);return{min:n,max:i}},_.image.Image.prototype.calculateHistogram=function(){for(var e,t=this.getGeometry().getSize(),n=[],i=this.getValueAtOffset(0),r=i,o=this.getRescaledValueAtOffset(0),a=o,s=0,u=t.getTotalSize();s<u;++s)r<(e=this.getValueAtOffset(s))&&(r=e),e<i&&(i=e),a<(e=this.getRescaledValueAtOffset(s))&&(a=e),e<o&&(o=e),n[e]=(n[e]||0)+1;for(var t={min:i,max:r},l={min:o,max:a},c=[],d=o;d<=a;++d)c.push([d,n[d]||0]);return{dataRange:t,rescaledDataRange:l,histogram:c}},_.image.Image.prototype.convolute2D=function(e){if(9!==e.length)throw new Error("The convolution matrix does not have a length of 9; it has "+e.length);for(var t=this.clone(),n=t.getBuffer(),i=this.getGeometry().getSize(),r=i.getDimSize(2)*this.getNumberOfComponents(),o=0;o<i.get(2);++o)this.convoluteBuffer(e,n,o*r);return t},_.image.Image.prototype.convoluteBuffer=function(e,t,n){for(var i=this.getGeometry().getSize(),r=i.get(0),o=i.get(1),a=this.getNumberOfComponents(),s=1,u=1,l=(3===a&&(0===this.getPlanarConfiguration()?s=3:u=i.getDimSize(2)),[]),c=(l[0]=(-r-1)*s,l[1]=-r*s,l[2]=(1-r)*s,l[3]=-s,l[4]=0,l[5]=+s,l[6]=(r-1)*s,l[7]=r*s,l[8]=(r+1)*s,[]),d=(c[0]=l[4],c[1]=l[4],c[2]=l[5],c[3]=l[4],c[4]=l[4],c[5]=l[5],c[6]=l[7],c[7]=l[7],c[8]=l[8],[]),g=(d[0]=l[1],d[1]=l[1],d[2]=l[2],d[3]=l[4],d[4]=l[4],d[5]=l[5],d[6]=l[7],d[7]=l[7],d[8]=l[8],[]),x=(g[0]=l[1],g[1]=l[1],g[2]=l[2],g[3]=l[4],g[4]=l[4],g[5]=l[5],g[6]=l[4],g[7]=l[4],g[8]=l[5],[]),S=(x[0]=l[3],x[1]=l[4],x[2]=l[5],x[3]=l[3],x[4]=l[4],x[5]=l[5],x[6]=l[6],x[7]=l[7],x[8]=l[8],[]),m=(S[0]=l[0],S[1]=l[1],S[2]=l[2],S[3]=l[3],S[4]=l[4],S[5]=l[5],S[6]=l[3],S[7]=l[4],S[8]=l[5],[]),h=(m[0]=l[3],m[1]=l[4],m[2]=l[4],m[3]=l[3],m[4]=l[4],m[5]=l[4],m[6]=l[6],m[7]=l[7],m[8]=l[7],[]),f=(h[0]=l[0],h[1]=l[1],h[2]=l[1],h[3]=l[3],h[4]=l[4],h[5]=l[4],h[6]=l[6],h[7]=l[7],h[8]=l[7],[]),p=(f[0]=l[0],f[1]=l[1],f[2]=l[1],f[3]=l[3],f[4]=l[4],f[5]=l[4],f[6]=l[3],f[7]=l[4],f[8]=l[4],n),y=0,D=[],v=0;v<a;++v){p+=v*u;for(var C=0;C<o;++C)for(var T=0;T<r;++T){D=l,0===T&&0===C?D=c:0===T&&C===o-1?D=g:T===r-1&&0===C?D=m:T===r-1&&C===o-1?D=f:0===T&&C!==o-1&&0!==C?D=d:T===r-1&&C!==o-1&&0!==C?D=h:0!==T&&T!==r-1&&0===C?D=x:0!==T&&T!==r-1&&C===o-1&&(D=S);for(var y=0,L=0;L<9;++L)y+=this.getValueAtOffset(p+D[L])*e[L];t[p]=y,p+=s}}},_.image.Image.prototype.transform=function(e){for(var t=this.clone(),n=t.getBuffer(),i=0,r=n.length;i<r;++i)n[i]=e(t.getValueAtOffset(i));return t},_.image.Image.prototype.compose=function(e,t){for(var n=this.clone(),i=n.getBuffer(),r=0,o=i.length;r<o;++r)i[r]=Math.floor(t(this.getValueAtOffset(r),e.getValueAtOffset(r)));return n},_||{}),_=(_.image=_.image||{},_.image.ImageFactory=function(){},_.ImageFactory=_.image.ImageFactory,_.image.ImageFactory.prototype.checkElements=function(e){if(!e.getFromKey("x00280011"))throw new Error("Missing or empty DICOM image number of columns");if(!e.getFromKey("x00280010"))throw new Error("Missing or empty DICOM image number of rows")},_.image.ImageFactory.prototype.create=function(e,t,n){var i=e.getFromKey("x00280011");if(!i)throw new Error("Missing or empty DICOM image number of columns");var r=e.getFromKey("x00280010");if(!r)throw new Error("Missing or empty DICOM image number of rows");var i=[i,r,1],r=e.getFromKey("x00280008"),r=(r&&i.push(r),new _.image.Size(i)),i=e.getPixelSpacing(),o=e.getFromKey("x00020010"),o=_.dicom.cleanString(o),a=_.dicom.isJpeg2000TransferSyntax(o),s=_.dicom.isJpegBaselineTransferSyntax(o),o=_.dicom.isJpegLosslessTransferSyntax(o),u=e.getFromKey("x00200032"),l=new Array(0,0,0),u=(u&&(l=[parseFloat(u[0]),parseFloat(u[1]),parseFloat(u[2])]),e.getFromKey("x00200037")),u=(u&&(d=new _.math.Vector3D(parseFloat(u[0]),parseFloat(u[1]),parseFloat(u[2])),u=new _.math.Vector3D(parseFloat(u[3]),parseFloat(u[4]),parseFloat(u[5])),c=d.crossProduct(u),d=new _.math.Matrix33([d.getX(),u.getX(),c.getX(),d.getY(),u.getY(),c.getY(),d.getZ(),u.getZ(),c.getZ()])),new _.math.Point3D(l[0],l[1],l[2])),c=e.getTime(),l=new _.image.Geometry(u,r,i,d,c),u=_.dicom.cleanString(e.getFromKey("x00080018")),i=(i=e.getFromKey("x00280002"))||1,d=r.getTotalSize()*i;if(d!==t.length){if(_.logger.warn("Badly sized pixel buffer: "+t.length+" != "+d),!(d<t.length))throw new Error("Underestimated buffer size, can't fix it...");t=t.slice(0,r.getTotalSize())}var c=new _.image.Image(l,t,[u]),d=e.getFromKey("x00280004"),l=(d&&(r=_.dicom.cleanString(d).toUpperCase(),c.setPhotometricInterpretation(r="RGB"===(r=(a||s||o)&&"MONOCHROME1"!==r&&"MONOCHROME2"!==r?"RGB":r)&&1===i?"PALETTE COLOR":r)),e.getFromKey("x00280006")),t=(l&&c.setPlanarConfiguration(l),1),u=e.getFromKey("x00281053"),d=(u&&(t=parseFloat(u)),0),a=e.getFromKey("x00281052"),s=(a&&(d=parseFloat(a)),new _.image.RescaleSlopeAndIntercept(t,d)),o=(c.setRescaleSlopeAndIntercept(s),{numberOfFiles:n,Modality:e.getFromKey("x00080060"),SOPClassUID:e.getFromKey("x00080016"),StudyInstanceUID:e.getFromKey("x0020000D"),SeriesInstanceUID:e.getFromKey("x0020000E"),BitsStored:e.getFromKey("x00280101"),PixelRepresentation:e.getFromKey("x00280103")}),i=(o.IsSigned=1===o.PixelRepresentation,e.getPixelUnit()),r=(i&&(o.pixelUnit=i),e.getFromKey("x00200052")),g=(r&&(o.FrameOfReferenceUID=r),{}),x=e.getFromKey("x00281050",!0),S=e.getFromKey("x00281051",!0),m=e.getFromKey("x00281055",!0);if(x&&S)for(var h,f=0;f<x.length;++f){var p=parseFloat(x[f],10),y=parseFloat(S[f],10);p&&y&&0!==y&&(g[h=(h="")===(h=m?_.dicom.cleanString(m[f]):h)?"Default"+f:h]={wl:[new _.image.WindowLevel(p,y)],name:h}),0===y&&_.logger.warn("Zero window width found in DICOM.")}o.windowPresets=g,"PALETTE COLOR"===c.getPhotometricInterpretation()&&(l=e.getFromKey("x00281201"),u=e.getFromKey("x00281202"),a=e.getFromKey("x00281203"),void 0!==(t=e.getFromKey("x00281101"))&&3===t.length&&(16===t[2]?(d=!1,0===(s=t[0])&&(s=65536),(n=e.getDEFromKey("x00281201").vl)!==2*s&&(d=!0,_.logger.info("16bits lut but size is not double. desc: "+s+" vl: "+n)),8===parseInt(e.getFromKey("x00280100"),10)&&(d=!0,_.logger.info("Scaling 16bits color lut since bits allocated is 8.")),d&&(l=l.map(i=function(e){return e>>8}),u=u.map(i),a=a.map(i))):8===t[2]&&(_.logger.info("Scaling 16bits color lut since the lut descriptor is 8."),r=l.slice(0),l=new Uint8Array(r.buffer),r=u.slice(0),u=new Uint8Array(r.buffer),r=a.slice(0),a=new Uint8Array(r.buffer))),o.paletteLut={red:l,green:u,blue:a});s=e.getFromKey("x00082144");return s&&(o.RecommendedDisplayFrameRate=parseInt(s,10)),c.setMeta(o),c},_||{}),_=(_.image=_.image||{},_.image.simpleRange=function(t,e,n,i){void 0===i&&(i=1);var r=e;return{next:function(){var e;return r<n?(e={value:t(r),done:!1,index:r},r+=i,e):{done:!0,index:n}}}},_.image.range=function(t,e,n,i,r,o,a,s){void 0===s&&(s=!1);var u=e,l=((a=void 0===a?!1:a)?(o*=-1,s?u-=(r-1)*i:i*=-1):s&&(u+=(r-1)*i,i*=-1),o-r*i),c=0,d=0;return{next:function(){var e;return c<n?(e={value:t(u),done:!1,index:u},u+=i,++c,++d===r&&(d=0,u+=l),e):{done:!0,index:u}}}},_.image.rangeRegion=function(t,e,n,i,r,o){var a=e,s=0;return{next:function(){var e;return a<n?(e={value:t(a),done:!1,index:a},a+=i,(s+=1)===r&&(s=0,a+=o),e):{done:!0,index:n}}}},_.image.rangeRegions=function(t,e,n,i,r){var o=e,a=0,s=0;return{next:function(){var e;return o<n?(e={value:t(o),done:!1,index:o},o+=i,(s+=1)===r[a][1]&&(s=0,o+=r[a][2],(a+=1)<r.length&&(o+=r[a][0])),e):{done:!0,index:n}}}},_.image.simpleRange3d=function(t,e,n,i,r){void 0===i&&(i=1);var o=e,a=1,s=((r=void 0===r?!1:r)?a=(n-e)/3:i*=3,o+a),u=o+2*a;return{next:function(){var e;return o<n?(e={value:[t(o),t(s),t(u)],done:!1,index:[o,s,u]},o+=i,s+=i,u+=i,e):{done:!0,index:[n]}}}},_.image.range3d=function(e,t,n,i,r,o,a,s,u){var l=[];return u?(l.push(_.image.range(e,t,n,i,r,o,a,s)),l.push(_.image.range(e,t+n*i,n,i,r,o,a,s)),l.push(_.image.range(e,t+2*n*i,n,i,r,o,a,s))):(l.push(_.image.range(e,t,n,i*=3,r,o*=3,a,s)),l.push(_.image.range(e,t+1,n,i,r,o,a,s)),l.push(_.image.range(e,t+2,n,i,r,o,a,s))),{next:function(){var e=l[0].next(),t=l[1].next(),n=l[2].next();return e.done?{done:!0,index:n.index}:{value:[e.value,t.value,n.value],done:!1,index:[e.index,t.index,n.index]}}}},_.image.getIteratorValues=function(e){for(var t=[],n=e.next();!n.done;)t.push(n.value),n=e.next();return t},_.image.getSliceIterator=function(t,e,n,i){function r(e,t,n,i,r,o,a,s){return 1===c?_.image.range(e,t,n,i,r,o,a,s):3===c?_.image.range3d(e,3*t,n,i,r,o,a,s,d):void 0}var o=t.getGeometry().getSize(),a=2,e=(i&&void 0!==i&&(a=i.getColAbsMax(2).index),e.getValues()),e=new _.math.Index(e.map(function(e,t){return t===a||2<t?e:0})),e=o.indexToOffset(e),s=null,s=(n=void 0===n?!1:n)?function(e){return t.getRescaledValueAtOffset(e)}:function(e){return t.getValueAtOffset(e)},n=o.get(0),u=o.get(1),l=o.get(2),o=o.getDimSize(2),c=t.getNumberOfComponents(),d=1===t.getPlanarConfiguration(),g=null;if(i&&void 0!==i){var x=i.getColAbsMax(0),i=i.getColAbsMax(2),S=null;if(2===i.index)S=n*u,g=0===x.index?r(s,e,S,1,n,n,!1,!1):r(s,e,S,n,u,1,!1,!1);else if(0===i.index)S=l*u,g=1===x.index?r(s,e,S,n,u,o,!1,!1):r(s,e,S,o,l,n,!1,!1);else{if(1!==i.index)throw new Error("Unknown direction: "+i.index);S=l*n,g=0===x.index?r(s,e,S,1,n,o,!1,!1):r(s,e,S,o,l,1,!1,!1)}}else if(1===t.getNumberOfComponents())g=_.image.simpleRange(s,e,e+o);else{if(3!==t.getNumberOfComponents())throw new Error("Unsupported number of components: "+t.getNumberOfComponents());g=_.image.simpleRange3d(s,e*=3,e+(o*=3),1,d)}return g},_.image.getRegionSliceIterator=function(t,e,n,i,r){if(1!==t.getNumberOfComponents())throw new Error("Unsupported number of components for region iterator: "+t.getNumberOfComponents());var o=null,o=(n=void 0===n?!1:n)?function(e){return t.getRescaledValueAtOffset(e)}:function(e){return t.getValueAtOffset(e)},n=t.getGeometry().getSize(),a=(void 0===i&&(i=new _.math.Point2D(0,0)),void 0===r&&(r=new _.math.Point2D(n.get(0)-1,n.get(1))),n.indexToOffset(e.getWithNew2D(i.getX(),i.getY()))),e=n.indexToOffset(e.getWithNew2D(r.getX(),r.getY()-1)),r=Math.max(1,r.getX()-i.getX()),i=n.get(0)-r;return _.image.rangeRegion(o,a,e+1,1,r,i)},_.image.getVariableRegionSliceIterator=function(t,e,n,i){if(1!==t.getNumberOfComponents())throw new Error("Unsupported number of components for region iterator: "+t.getNumberOfComponents());for(var r,o=null,o=(n=void 0===n?!1:n)?function(e){return t.getRescaledValueAtOffset(e)}:function(e){return t.getValueAtOffset(e)},a=t.getGeometry().getSize(),s=[],u=null,n=null,l=null,c=0;c<i.length;++c){var d,g=(d=i[c])[1][0]-d[0][0];0!=g&&(l=c,u=u||d[0],s.push([d[0][0],g,a.get(0)-d[1][0]]))}if(null!==l&&(n=i[l][1]),0!==s.length)return r=a.indexToOffset(e.getWithNew2D(u[0],u[1])),e=a.indexToOffset(e.getWithNew2D(n[0],n[1])),_.image.rangeRegions(o,r,e+1,1,s)},_.image.colourRange=function(t,n){var i=0,r=0;return{next:function(){var e;return i<n?(r+1<t.length&&i>=t[r+1].index&&++r,e={value:t[r].colour,done:!1,index:i},++i,e):{done:!0,index:n}}}},_||{}),_=(_.image=_.image||{},_.image.lut=_.image.lut||{},_.image.lut.range_max=256,_.image.lut.buildLut=function(e){for(var t=[],n=0;n<_.image.lut.range_max;++n)t.push(e(n));return t},_.image.lut.max=function(e){return _.image.lut.range_max-1},_.image.lut.maxFirstThird=function(e){return e<_.image.lut.range_max/3?_.image.lut.range_max-1:0},_.image.lut.maxSecondThird=function(e){var t=_.image.lut.range_max/3;return t<=e&&e<2*t?_.image.lut.range_max-1:0},_.image.lut.maxThirdThird=function(e){return e>=2*_.image.lut.range_max/3?_.image.lut.range_max-1:0},_.image.lut.toMaxFirstThird=function(e){e*=3;return e>_.image.lut.range_max-1?_.image.lut.range_max-1:e},_.image.lut.toMaxSecondThird=function(e){var t=_.image.lut.range_max/3,n=0;return t<=e&&(n=3*(e-t))>_.image.lut.range_max-1?_.image.lut.range_max-1:n},_.image.lut.toMaxThirdThird=function(e){var t=_.image.lut.range_max/3,n=0;return 2*t<=e&&(n=3*(e-2*t))>_.image.lut.range_max-1?_.image.lut.range_max-1:n},_.image.lut.zero=function(e){return 0},_.image.lut.id=function(e){return e},_.image.lut.invId=function(e){return _.image.lut.range_max-1-e},_.image.lut.plain={red:_.image.lut.buildLut(_.image.lut.id),green:_.image.lut.buildLut(_.image.lut.id),blue:_.image.lut.buildLut(_.image.lut.id)},_.image.lut.invPlain={red:_.image.lut.buildLut(_.image.lut.invId),green:_.image.lut.buildLut(_.image.lut.invId),blue:_.image.lut.buildLut(_.image.lut.invId)},_.image.lut.rainbow={blue:[0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224,228,232,236,240,244,248,252,255,247,239,231,223,215,207,199,191,183,175,167,159,151,143,135,127,119,111,103,95,87,79,71,63,55,47,39,31,23,15,7,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,16,24,32,40,48,56,64,72,80,88,96,104,112,120,128,136,144,152,160,168,176,184,192,200,208,216,224,232,240,248,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,253,251,249,247,245,243,241,239,237,235,233,231,229,227,225,223,221,219,217,215,213,211,209,207,205,203,201,199,197,195,193,192,189,186,183,180,177,174,171,168,165,162,159,156,153,150,147,144,141,138,135,132,129,126,123,120,117,114,111,108,105,102,99,96,93,90,87,84,81,78,75,72,69,66,63,60,57,54,51,48,45,42,39,36,33,30,27,24,21,18,15,12,9,6,3],red:[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,62,60,58,56,54,52,50,48,46,44,42,40,38,36,34,32,30,28,26,24,22,20,18,16,14,12,10,8,6,4,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224,228,232,236,240,244,248,252,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255]},_.image.lut.hot={red:_.image.lut.buildLut(_.image.lut.toMaxFirstThird),green:_.image.lut.buildLut(_.image.lut.toMaxSecondThird),blue:_.image.lut.buildLut(_.image.lut.toMaxThirdThird)},_.image.lut.hot_iron={red:[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,172,174,176,178,180,182,184,186,188,190,192,194,196,198,200,202,204,206,208,210,212,214,216,218,220,222,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,254,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,172,174,176,178,180,182,184,186,188,190,192,194,196,198,200,202,204,206,208,210,212,214,216,218,220,222,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,255],blue:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224,228,232,236,240,244,248,252,255]},_.image.lut.pet={red:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,171,173,175,177,179,181,183,185,187,189,191,193,195,197,199,201,203,205,207,209,211,213,215,217,219,221,223,225,227,229,231,233,235,237,239,241,243,245,247,249,251,253,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97,99,101,103,105,107,109,111,113,115,117,119,121,123,125,128,126,124,122,120,118,116,114,112,110,108,106,104,102,100,98,96,94,92,90,88,86,84,82,80,78,76,74,72,70,68,66,64,63,61,59,57,55,53,51,49,47,45,43,41,39,37,35,33,31,29,27,25,23,21,19,17,15,13,11,9,7,5,3,1,0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,172,174,176,178,180,182,184,186,188,190,192,194,196,198,200,202,204,206,208,210,212,214,216,218,220,222,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,255],blue:[0,1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97,99,101,103,105,107,109,111,113,115,117,119,121,123,125,127,129,131,133,135,137,139,141,143,145,147,149,151,153,155,157,159,161,163,165,167,169,171,173,175,177,179,181,183,185,187,189,191,193,195,197,199,201,203,205,207,209,211,213,215,217,219,221,223,225,227,229,231,233,235,237,239,241,243,245,247,249,251,253,255,252,248,244,240,236,232,228,224,220,216,212,208,204,200,196,192,188,184,180,176,172,168,164,160,156,152,148,144,140,136,132,128,124,120,116,112,108,104,100,96,92,88,84,80,76,72,68,64,60,56,52,48,44,40,36,32,28,24,20,16,12,8,4,0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,85,89,93,97,101,105,109,113,117,121,125,129,133,137,141,145,149,153,157,161,165,170,174,178,182,186,190,194,198,202,206,210,214,218,222,226,230,234,238,242,246,250,255]},_.image.lut.hot_metal_blue={red:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,6,9,12,15,18,21,24,26,29,32,35,38,41,44,47,50,52,55,57,59,62,64,66,69,71,74,76,78,81,83,85,88,90,93,96,99,102,105,108,111,114,116,119,122,125,128,131,134,137,140,143,146,149,152,155,158,161,164,166,169,172,175,178,181,184,187,190,194,198,201,205,209,213,217,221,224,228,232,236,240,244,247,251,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,6,8,9,11,13,15,17,19,21,23,24,26,28,30,32,34,36,38,40,41,43,45,47,49,51,53,55,56,58,60,62,64,66,68,70,72,73,75,77,79,81,83,85,87,88,90,92,94,96,98,100,102,104,105,107,109,111,113,115,117,119,120,122,124,126,128,130,132,134,136,137,139,141,143,145,147,149,151,152,154,156,158,160,162,164,166,168,169,171,173,175,177,179,181,183,184,186,188,190,192,194,196,198,200,201,203,205,207,209,211,213,215,216,218,220,222,224,226,228,229,231,233,235,237,239,240,242,244,246,248,250,251,253,255],blue:[0,2,4,6,8,10,12,14,16,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,117,119,121,123,125,127,129,131,133,135,137,139,141,143,145,147,149,151,153,155,157,159,161,163,165,167,169,171,173,175,177,179,181,183,184,186,188,190,192,194,196,198,200,197,194,191,188,185,182,179,176,174,171,168,165,162,159,156,153,150,144,138,132,126,121,115,109,103,97,91,85,79,74,68,62,56,50,47,44,41,38,35,32,29,26,24,21,18,15,12,9,6,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,6,9,12,15,18,21,24,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,126,129,132,135,138,141,144,147,150,153,156,159,162,165,168,171,174,176,179,182,185,188,191,194,197,200,203,206,210,213,216,219,223,226,229,232,236,239,242,245,249,252,255]},_.image.lut.pet_20step={red:[0,0,0,0,0,0,0,0,0,0,0,0,0,96,96,96,96,96,96,96,96,96,96,96,96,96,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,96,96,96,96,96,96,96,96,96,96,96,96,96,112,112,112,112,112,112,112,112,112,112,112,112,112,128,128,128,128,128,128,128,128,128,128,128,128,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,64,64,64,64,64,64,64,64,64,64,64,64,224,224,224,224,224,224,224,224,224,224,224,224,224,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,192,192,192,192,192,192,192,192,192,192,192,192,192,176,176,176,176,176,176,176,176,176,176,176,176,176,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,96,96,96,96,96,96,96,96,96,96,96,96,96,112,112,112,112,112,112,112,112,112,112,112,112,112,128,128,128,128,128,128,128,128,128,128,128,128,96,96,96,96,96,96,96,96,96,96,96,96,96,144,144,144,144,144,144,144,144,144,144,144,144,144,192,192,192,192,192,192,192,192,192,192,192,192,192,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,208,208,208,208,208,208,208,208,208,208,208,208,208,176,176,176,176,176,176,176,176,176,176,176,176,176,144,144,144,144,144,144,144,144,144,144,144,144,96,96,96,96,96,96,96,96,96,96,96,96,96,48,48,48,48,48,48,48,48,48,48,48,48,48,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255],blue:[0,0,0,0,0,0,0,0,0,0,0,0,0,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,112,112,112,112,112,112,112,112,112,112,112,112,128,128,128,128,128,128,128,128,128,128,128,128,128,176,176,176,176,176,176,176,176,176,176,176,176,176,192,192,192,192,192,192,192,192,192,192,192,192,192,224,224,224,224,224,224,224,224,224,224,224,224,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,64,64,64,64,64,64,64,64,64,64,64,64,80,80,80,80,80,80,80,80,80,80,80,80,80,96,96,96,96,96,96,96,96,96,96,96,96,96,64,64,64,64,64,64,64,64,64,64,64,64,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255]},_.image.lut.test={red:_.image.lut.buildLut(_.image.lut.id),green:_.image.lut.buildLut(_.image.lut.zero),blue:_.image.lut.buildLut(_.image.lut.zero)},_||{}),_=(_.image=_.image||{},_.dicom.equalPosPat=function(e,t){return JSON.stringify(e)===JSON.stringify(t)},_.dicom.getComparePosPat=function(e){var n=e.getInverse();return function(e,t){e=n.multiplyArray3D(e),t=n.multiplyArray3D(t);return e[2]-t[2]}},_.dicom.checkTag=function(e,t){var n=e.getFromKey(t.tag);if(1===t.type||2===t.type){if(null==n)throw new Error("Missing or empty "+t.name)}else if(null==n)return;var i=!1;if(Array.isArray(n))for(var n=n.map(function(e){return _.dicom.cleanString(e)}),r=0;r<t.enum.length;++r){if(!Array.isArray(t.enum[r]))throw new Error("Cannot compare array and non array tag value.");if(_.utils.arraySortEquals(t.enum[r],n)){i=!0;break}}else"string"==typeof n&&(n=_.dicom.cleanString(n)),i=t.enum.includes(n);if(!i)throw new Error("Unsupported "+t.name+" value: "+n)},_.dicom.requiredDicomSegTags=[{name:"TransferSyntaxUID",tag:"x00020010",type:"1",enum:["1.2.840.10008.1.2.1"]},{name:"MediaStorageSOPClassUID",tag:"x00020002",type:"1",enum:["1.2.840.10008.5.1.4.1.1.66.4"]},{name:"SOPClassUID",tag:"x00020002",type:"1",enum:["1.2.840.10008.5.1.4.1.1.66.4"]},{name:"Modality",tag:"x00080060",type:"1",enum:["SEG"]},{name:"SegmentationType",tag:"x00620001",type:"1",enum:["BINARY"]},{name:"DimensionOrganizationType",tag:"x00209311",type:"3",enum:["3D"]},{name:"ImageType",tag:"x00080008",type:"1",enum:[["DERIVED","PRIMARY"]]},{name:"SamplesPerPixel",tag:"x00280002",type:"1",enum:[1]},{name:"PhotometricInterpretation",tag:"x00280004",type:"1",enum:["MONOCHROME2"]},{name:"PixelRepresentation",tag:"x00280103",type:"1",enum:[0]},{name:"BitsAllocated",tag:"x00280100",type:"1",enum:[1]},{name:"BitsStored",tag:"x00280101",type:"1",enum:[1]},{name:"HighBit",tag:"x00280102",type:"1",enum:[0]}],_.dicom.getDefaultDicomSegJson=function(){for(var e={},t=0;t<_.dicom.requiredDicomSegTags.length;++t){var n=_.dicom.requiredDicomSegTags[t];e[n.name]=n.enum[0]}return e},_.dicom.getDimensionOrganization=function(e){var t=e.getFromKey("x00209221",!0);if(!t||1!==t.length)throw new Error("Unsupported dimension organization sequence length");var n=_.dicom.cleanString(t[0].x00209164.value[0]),i=[],r=e.getFromKey("x00209222",!0);if(r){if(2!==r.length)throw new Error("Unsupported dimension index sequence length");for(var o=0;o<r.length;++o){var a=_.dicom.cleanString(r[o].x00209164.value[0]);if(a!==n)throw new Error("Dimension Index Sequence contains a unknown Dimension Organization");var s,a={DimensionOrganizationUID:a,DimensionIndexPointer:s=_.dicom.cleanString(r[o].x00209165.value[0])};void 0!==r[o].x00209421&&(a.DimensionDescriptionLabel=_.dicom.cleanString(r[o].x00209421.value[0])),i.push(a)}if("(0020,0032)"!==s)throw new Error("Unsupported non image position as last index")}return{organizations:{value:[{DimensionOrganizationUID:n}]},indices:{value:i}}},_.dicom.getCode=function(e){var t={meaning:_.dicom.cleanString(e.x00080104.value[0])};if(e.x00080100)t.value=e.x00080100.value[0];else if(e.x00080119)t.longValue=e.x00080119.value[0];else{if(!e.x00080120)throw Error("Invalid code with no value, no long value and no urn value.");t.urnValue=e.x00080120.value[0]}if(void 0!==t.value||void 0!==t.longValue){if(!e.x00080102)throw Error("No coding sheme designator when code value or long value is present");t.schemeDesignator=e.x00080102.value[0]}return t},_.dicom.getSegment=function(e){var t,n={number:e.x00620004.value[0],label:_.dicom.cleanString(e.x00620005.value[0]),algorithmType:_.dicom.cleanString(e.x00620008.value[0])};if(e.x00620009&&(n.algorithmName=_.dicom.cleanString(e.x00620009.value[0])),void 0!==e.x0062000C?n.displayValue=e.x006200C.value:void 0!==e.x0062000D&&(t=e.x0062000D.value,t=_.utils.cielabToSrgb(_.utils.uintLabToLab({l:t[0],a:t[1],b:t[2]})),n.displayValue=t),void 0===e.x00620003)throw Error("Missing Segmented Property Category Code Sequence.");if(n.propertyCategoryCode=_.dicom.getCode(e.x00620003.value[0]),void 0===e.x0062000F)throw Error("Missing Segmented Property Type Code Sequence.");return n.propertyTypeCode=_.dicom.getCode(e.x0062000F.value[0]),void 0!==e.x00620020&&(n.trackingId=e.x00620020.value[0],n.trackingUid=e.x00620021.value[0]),n},_.dicom.isEqualSegment=function(e,t){if(void 0===e||void 0===t||null===e||null===t)return!1;var n=e.number===t.number&&e.label===t.label&&e.algorithmType===t.algorithmType,n=void 0!==e.displayValue.r?void 0!==t.displayValue.r&&(n&&_.utils.isEqualRgb(e.displayValue,t.displayValue)):n&&e.displayValue===t.displayValue;return n=void 0!==e.algorithmName?void 0!==t.algorithmName&&(n&&e.algorithmName===t.algorithmName):n},_.dicom.isSimilarSegment=function(e,t){if(void 0===e||void 0===t||null===e||null===t)return!1;var n=e.number===t.number;return n=void 0!==e.displayValue.r?void 0!==t.displayValue.r&&(n||_.utils.isEqualRgb(e.displayValue,t.displayValue)):n||e.displayValue===t.displayValue},_.dicom.getSpacingFromMeasure=function(e){if(void 0===e.x00280030)return null;var t=e.x00280030,t=[parseFloat(t.value[0]),parseFloat(t.value[1])];return void 0!==e.x00180050?t.push(parseFloat(e.x00180050.value[0])):void 0!==e.x00180088&&t.push(parseFloat(e.x00180088.value[0])),new _.image.Spacing(t)},_.dicom.getSegmentFrameInfo=function(e){var t=[];if(void 0!==e.x00089124)for(var n=e.x00089124.value,i=0;i<n.length;++i){var r=[];if(void 0!==n[i].x00082112)for(var o=n[i].x00082112.value,a=0;a<o.length;++a){var s={};void 0!==o[a].x00081150&&(s.referencedSOPClassUID=o[a].x00081150.value[0]),void 0!==o[a].x00081155&&(s.referencedSOPInstanceUID=o[a].x00081155.value[0]),r.push(s)}t.push(r)}for(var u=e.x00209111.value[0].x00209157.value,l=e.x0062000A.value[0].x0062000B.value[0],c=e.x00209113.value[0].x00200032.value,d=0;d<c.length;++d)c[d]=parseFloat(c[d],10);u={dimIndex:u,imagePosPat:c,derivationImages:t,refSegmentNumber:l};return void 0!==e.x00209116&&0!==(l=e.x00209116).value.length&&void 0!==(l=l.value[0].x00200037.value)&&(u.imageOrientationPatient=l),void 0!==e.x00289110&&(0!==(l=e.x00289110).value.length?void 0!==(e=_.dicom.getSpacingFromMeasure(l.value[0]))&&(u.spacing=e):_.logger.warn("No shared functional group pixel measure sequence items.")),u},_.image.MaskFactory=function(){},_.image.MaskFactory.prototype.create=function(e,t){for(var n=0;n<_.dicom.requiredDicomSegTags.length;++n)_.dicom.checkTag(e,_.dicom.requiredDicomSegTags[n]);var i=e.getFromKey("x00280011");if(!i)throw new Error("Missing or empty DICOM image number of columns");var r=e.getFromKey("x00280010");if(!r)throw new Error("Missing or empty DICOM image number of rows");var o=i*r,i=e.getFromKey("x00280008");if((i=i?parseInt(i,10):1)!==t.length/o)throw new Error("Buffer and numberOfFrames meta are not equal."+i+" "+t.length/o);var r=_.dicom.getDimensionOrganization(e),a=e.getFromKey("x00620002",!0);if(!a||void 0===a)throw new Error("Missing or empty segmentation sequence");for(var s=[],u=!1,l=0;l<a.length;++l){var c=_.dicom.getSegment(a[l]);void 0!==c.displayValue.r&&void 0!==c.displayValue.g&&void 0!==c.displayValue.b&&(u=!0),s.push(c)}var d,g,x=e.getImageSize(),S=e.getFromKey("x52009229",!0),m=(S&&0!==S.length&&(void 0!==(S=S[0]).x00209116&&(0!==(D=S.x00209116).value.length?g=D.value[0].x00200037.value:_.logger.warn("No shared functional group plane orientation sequence items.")),void 0!==S.x00289110&&(0!==(D=S.x00289110).value.length?d=_.dicom.getSpacingFromMeasure(D.value[0]):_.logger.warn("No shared functional group pixel measure sequence items."))),e.getFromKey("x52009230",!0));if(!m||void 0===m)throw new Error("Missing or empty per frame functional sequence");if(i!==m.length)throw new Error("perFrameFuncGroupSequence meta and numberOfFrames are not equal.");for(var h=[],f=0;f<m.length;++f)h.push(_.dicom.getSegmentFrameInfo(m[f]));for(var p=[],y=0;y<h.length;++y){if(!function(e,t){return e.some(function(e){return _.dicom.equalPosPat(t,e)})}(p,h[y].imagePosPat)&&p.push(h[y].imagePosPat),void 0!==h[y].imageOrientationPatient)if(void 0===g)g=h[y].imageOrientationPatient;else if(!_.utils.arraySortEquals(g,h[y].imageOrientationPatient))throw new Error("Unsupported multi orientation dicom seg.");if(void 0!==h[y].spacing)if(void 0===d)d=h[y].spacing;else if(!d.equals(h[y].spacing))throw new Error("Unsupported multi resolution dicom seg.")}if(void 0===d)throw new Error("No spacing found for DICOM SEG");if(void 0===g)throw new Error("No imageOrientationPatient found for DICOM SEG");function M(e){return new _.math.Point3D(e[0],e[1],e[2])}for(var S=new _.math.Vector3D(parseFloat(g[0]),parseFloat(g[1]),parseFloat(g[2])),D=new _.math.Vector3D(parseFloat(g[3]),parseFloat(g[4]),parseFloat(g[5])),i=S.crossProduct(D),S=new _.math.Matrix33([S.getX(),D.getX(),i.getX(),S.getY(),D.getY(),i.getY(),S.getZ(),D.getZ(),i.getZ()]),v=(p.sort(_.dicom.getComparePosPat(S)),[]),C=0;C<p.length;++C)v.push(M(p[C]));for(var T,L,D=d,i=_.image.getSliceGeometrySpacing(v,S,!1),I=d.getValues(),Q=(void 0!==i&&i!==I[2]&&(I[2]=i,D=new _.image.Spacing(I)),new _.image.Geometry(v[0],x,D,S)),P=[],w=(P.push(p[0]),0),A=1;A<p.length;++A){++w;for(var B=new _.math.Index([0,0,w]),F=Q.indexToWorld(B).get3D(),V=v[A],N=V.getDistance(F),G=N;L=void 0,(L=(T=N)>_.math.REAL_WORLD_EPSILON)&&((L=T>10*_.math.REAL_WORLD_EPSILON)?(L=T>100*_.math.REAL_WORLD_EPSILON)||_.logger.warn("Using even larger real world epsilon in SEG pos pat adding"):_.logger.warn("Using larger real world epsilon in SEG pos pat adding")),L;)if(_.logger.debug("Adding intermediate pos pats for DICOM seg at "+F.toString()),P.push([F.getX(),F.getY(),F.getZ()]),++w,B=new _.math.Index([0,0,w]),F=Q.indexToWorld(B).get3D(),G<(N=V.getDistance(F)))throw new Error("Test distance is increasing when adding intermediate pos pats");P.push(p[A])}for(var k=P.length,W=new _.image.Geometry(v[0],x,D,S),H=[0],O=1;O<k;++O)W.appendOrigin(M(P[O]),O),H.push(O);for(var z=u?3:1,R=new t.constructor(z*o*k),b=(R.fill(0),0);b<h.length;++b)for(var E,X=o*b,Y=o*(w=function(e,t){return e.findIndex(function(e){return _.dicom.equalPosPat(t,e)})}(P,h[b].imagePosPat)),q=s.find(function(t){return function(e){return e.number===t}}(h[b].refSegmentNumber)).displayValue,U=0;U<o;++U)0!==t[X+U]&&(E=z*(Y+U),u?(R[E]=q.r,R[1+E]=q.g,R[2+E]=q.b):R[E]=q);i=new _.image.Image(W,R,H),u&&i.setPhotometricInterpretation("RGB"),I=_.dicom.getDefaultDicomSegJson(),I.StudyDate=e.getFromKey("x00080020"),I.StudyTime=e.getFromKey("x00080030"),I.StudyInstanceUID=e.getFromKey("x0020000D"),I.StudyID=e.getFromKey("x00200010"),I.SeriesInstanceUID=e.getFromKey("x0020000E"),I.SeriesNumber=e.getFromKey("x00200011"),I.ReferringPhysicianName=e.getFromKey("x00080090"),I.PatientName=_.dicom.cleanString(e.getFromKey("x00100010")),I.PatientID=_.dicom.cleanString(e.getFromKey("x00100020")),I.PatientBirthDate=e.getFromKey("x00100030"),I.PatientSex=_.dicom.cleanString(e.getFromKey("x00100040")),I.Manufacturer=e.getFromKey("x00080070"),I.ManufacturerModelName=e.getFromKey("x00081090"),I.DeviceSerialNumber=e.getFromKey("x00181000"),I.SoftwareVersions=e.getFromKey("x00181020"),I.DimensionOrganizationSequence=r.organizations,I.DimensionIndexSequence=r.indices,I.custom={segments:s,frameInfos:h,SOPInstanceUID:e.getFromKey("x00080018")},I.numberOfFiles=k,x=e.getFromKey("x00200052"),x&&(I.FrameOfReferenceUID=x),D=e.getFromKey("x00282110");return D&&(I.LossyImageCompression=D),i.setMeta(I),i},_||{}),_=(_.image=_.image||{},_.image.MaskSegmentHelper=function(s){var n=s.getMeta().custom.segments,i=[];function r(t){return i.findIndex(function(e){return e===t})}this.hasSegment=function(e){return void 0!==this.getSegment(e)},this.maskHasSegments=function(e){for(var t=[],n=[],i=0;i<e.length;++i){var r=this.getSegment(e[i]);void 0!==r?t.push(r.displayValue):(_.logger.warn("Unknown segment in maskHasSegments: "+e[i]),n.push(i))}for(var o=s.hasValues(t),a=0;a<n.length;++a)o.splice(n[a],0,!1);return o},this.getSegment=function(t){return n.find(function(e){return e.number===t})},this.getSegments=function(){return n},this.setSegments=function(e){n=e},this.setHiddenSegments=function(e){i=e},this.isHidden=function(e){return-1!==r(e)},this.addToHidden=function(e){this.isHidden(e)?_.logger.warn("Segment is allready in the hidden list: "+e):i.push(e)},this.removeFromHidden=function(e){var t=r(e);-1!==t?i.splice(t,1):_.logger.warn("Segment is not in the hidden list: "+e)},this.getAlphaFunc=function(){for(var n=[{r:0,g:0,b:0}],e=0;e<i.length;++e){var t=this.getSegment(i[e]);void 0!==t&&n.push(t.displayValue)}return function(e){for(var t=0;t<n.length;++t)if(e[0]===n[t].r&&e[1]===n[t].g&&e[2]===n[t].b)return 0;return 255}},this.deleteSegment=function(e,t,n){var i=new _.image.DeleteSegmentCommand(s,this.getSegment(e));i.onExecute=t,i.onUndo=t,i.isValid()&&(i.execute(),n(i),this.isHidden(e)&&this.removeFromHidden(e))}},_.image.DeleteSegmentCommand=function(e,t,n){var i=void 0!==n&&n,r=e.getOffsets(t.displayValue);this.getName=function(){return"Delete-segment"},this.isValid=function(){return 0!==r.length},this.execute=function(){e.setAtOffsets(r,{r:0,g:0,b:0}),i||this.onExecute({type:"masksegmentdelete",segmentnumber:t.number})},this.undo=function(){e.setAtOffsets(r,t.displayValue),this.onUndo({type:"masksegmentredraw",segmentnumber:t.number})}},_.image.DeleteSegmentCommand.prototype.onExecute=function(e){},_.image.DeleteSegmentCommand.prototype.onUndo=function(e){},_||{}),_=(_.image=_.image||{},_.image.PlaneHelper=function(t,e,n){var i=_.gui.getTargetOrientation(e,n);this.getOffset3DFromPlaneOffset=function(e){e=new _.math.Vector3D(e.x,e.y,0),e=this.getTargetDeOrientedVector3D(e);return new _.math.Vector3D(e.getX()*t.get(0),e.getY()*t.get(1),e.getZ()*t.get(2))},this.getPlaneOffsetFromOffset3D=function(e){e=new _.math.Vector3D(e.x/t.get(0),e.y/t.get(1),e.z/t.get(2)),e=this.getTargetOrientedVector3D(e);return{x:e.getX(),y:e.getY()}},this.getTargetOrientedVector3D=function(e){var t=e;return t=void 0!==i?i.getInverse().multiplyVector3D(e):t},this.getTargetDeOrientedVector3D=function(e){var t=e;return t=void 0!==i?i.multiplyVector3D(e):t},this.getImageOrientedVector3D=function(e){var t=e;return void 0!==n&&(e=_.image.getDeOrientedArray3D([e.getX(),e.getY(),e.getZ()],n),t=new _.math.Vector3D(e[0],e[1],e[2])),t},this.getImageDeOrientedVector3D=function(e){var t=e;return void 0!==n&&(e=_.image.getOrientedArray3D([e.getX(),e.getY(),e.getZ()],n),t=new _.math.Vector3D(e[0],e[1],e[2])),t},this.getTargetOrientedPositiveXYZ=function(e){e=_.image.getOrientedArray3D([e.x,e.y,e.z],i);return{x:e[0],y:e[1],z:e[2]}},this.getScrollIndex=function(){return void 0!==n?n.getThirdColMajorDirection():2},this.getNativeScrollIndex=function(){return void 0!==e?e.getThirdColMajorDirection():2}},_||{}),_=(_.image=_.image||{},_.image.RescaleLut=function(t,e){var n=null,i=!1,r=Math.pow(2,e);this.getRSI=function(){return t},this.isReady=function(){return i},this.initialise=function(){if(!i){n=new Float32Array(r);for(var e=0;e<r;++e)n[e]=t.apply(e);i=!0}},this.getLength=function(){return r},this.getValue=function(e){return n[e]}},_||{}),_=(_.image=_.image||{},_.image.RescaleSlopeAndIntercept=function(t,n){this.getSlope=function(){return t},this.getIntercept=function(){return n},this.apply=function(e){return e*t+n}},_.image.RescaleSlopeAndIntercept.prototype.equals=function(e){return null!==e&&this.getSlope()===e.getSlope()&&this.getIntercept()===e.getIntercept()},_.image.RescaleSlopeAndIntercept.prototype.toString=function(){return this.getSlope()+", "+this.getIntercept()},_.image.RescaleSlopeAndIntercept.prototype.isID=function(){return 1===this.getSlope()&&0===this.getIntercept()},_||{}),_=(_.image=_.image||{},_.image.Size=function(t){if(!t||void 0===t)throw new Error("Cannot create size with no values.");if(0===t.length)throw new Error("Cannot create size with empty values.");if(!t.every(function(e){return!isNaN(e)&&0!==e}))throw new Error("Cannot create size with non number or zero values.");this.get=function(e){return t[e]},this.length=function(){return t.length},this.toString=function(){return"("+t.toString()+")"},this.getValues=function(){return t.slice()}},_.image.Size.prototype.moreThanOne=function(e){return this.length()>=e+1&&1!==this.get(e)},_.image.Size.prototype.canScroll3D=function(e){var t=2;return void 0!==e&&(t=e.getThirdColMajorDirection()),this.moreThanOne(t)},_.image.Size.prototype.canScroll=function(e){for(var t=this.canScroll3D(e),n=3;n<this.length();++n)t=t||this.moreThanOne(n);return t},_.image.Size.prototype.getDimSize=function(e,t){if(e>this.length())return null;if(void 0===t)t=0;else if(t<0||e<t)throw new Error("Invalid start value for getDimSize");for(var n=1,i=t;i<e;++i)n*=this.get(i);return n},_.image.Size.prototype.getTotalSize=function(e){return this.getDimSize(this.length(),e)},_.image.Size.prototype.equals=function(e){if(!e)return!1;var t=this.length();if(t!==e.length())return!1;for(var n=0;n<t;++n)if(this.get(n)!==e.get(n))return!1;return!0},_.image.Size.prototype.isInBounds=function(e,t){if(!e)return!1;var n=this.length();if(n!==e.length())return!1;if(void 0===t){t=[];for(var i=0;i<n;++i)t.push(i)}else for(var r=0;r<n;++r)if(t[r]>n-1)throw new Error("Wrong input dir value: "+t[r]);for(var o,a,s=0;s<t.length;++s)if(o=e.get(t[s]),a=this.get(t[s]),!(0<=o&&o<a))return!1;return!0},_.image.Size.prototype.indexToOffset=function(e,t){if(e.length()<this.length())throw new Error("Incompatible index and size length");if(void 0===t)t=0;else if(t<0||t>this.length()-1)throw new Error("Invalid start value for indexToOffset");for(var n=0,i=t;i<this.length();++i)n+=e.get(i)*this.getDimSize(i,t);return n},_.image.Size.prototype.offsetToIndex=function(e){for(var t,n=new Array(this.length()),i=e,r=this.length()-1;0<r;--r)t=this.getDimSize(r),n[r]=Math.floor(i/t),i-=n[r]*t;return n[0]=i,new _.math.Index(n)},_.image.Size.prototype.get2D=function(){return{x:this.get(0),y:this.get(1)}},_||{}),_=(_.image=_.image||{},_.image.Spacing=function(t){if(!t||void 0===t)throw new Error("Cannot create spacing with no values.");if(0===t.length)throw new Error("Cannot create spacing with empty values.");if(!t.every(function(e){return!isNaN(e)&&0!==e}))throw new Error("Cannot create spacing with non number or zero values.");this.get=function(e){return t[e]},this.length=function(){return t.length},this.toString=function(){return"("+t.toString()+")"},this.getValues=function(){return t.slice()}},_.image.Spacing.prototype.equals=function(e){if(!e)return!1;var t=this.length();if(t!==e.length())return!1;for(var n=0;n<t;++n)if(this.get(n)!==e.get(n))return!1;return!0},_.image.Spacing.prototype.get2D=function(){return{x:this.get(0),y:this.get(1)}},_||{}),_=(_.image=_.image||{},_.image.viewEventNames=["wlchange","wlpresetadd","colourchange","positionchange","opacitychange","alphafuncchange"],_.image.View=function(g){var t,n=this,i=(g.addEventListener("appendframe",function(){var e=n.getCurrentIndex();3===e.length()&&((e=e.getValues()).push(0),n.setCurrentIndex(new _.math.Index(e)))}),{}),r={minmax:{name:"minmax"}},s=null,u=null,o=_.image.lut.plain,x=null,a=new _.utils.ListenerHandler,l=(this.getImage=function(){return g},this.setImage=function(e){g=e},this.getOrientation=function(){return t},this.setOrientation=function(e){t=e},this.init=function(){this.setInitialIndex()},this.setInitialIndex=function(){var e=g.getGeometry().getSize(),t=new Array(e.length());t.fill(0),t[0]=Math.floor(e.get(0)/2),t[1]=Math.floor(e.get(1)/2),t[2]=Math.floor(e.get(2)/2),this.setCurrentIndex(new _.math.Index(t),!0)},this.getPlaybackMilliseconds=function(e){return e=e||10,Math.round(1e3/e)},function(e,t){return 255});function S(e){a.fireEvent(e)}this.getAlphaFunction=function(){return l},this.setAlphaFunction=function(e){l=e,S({type:"alphafuncchange"})},this.getCurrentWindowLut=function(e){this.getCurrentIndex()||this.setInitialIndex();var t=this.getCurrentIndex(),n=(void 0===e&&(e=g.getRescaleSlopeAndIntercept(t)),null),t=(s&&void 0!==r[s]&&void 0!==r[s].perslice&&!0===r[s].perslice&&(t=g.getSecondaryOffset(t),n=r[s].wl[t]),n||(u||this.setWindowLevelPresetById(0,!0),n=u),i[e.toString()]),e=(void 0===t&&(e=new _.image.RescaleLut(g.getRescaleSlopeAndIntercept(0),g.getMeta().BitsStored),e=new _.image.WindowLut(e,g.getMeta().IsSigned),this.addWindowLut(e),t=e),t.getWindowLevel());return n.equals(e)||(t.setWindowLevel(n),t.update(),e&&e.getWidth()===n.getWidth()&&e.getCenter()===n.getCenter()||S({type:"wlchange",value:[n.getCenter(),n.getWidth()],wc:n.getCenter(),ww:n.getWidth(),skipGenerate:!0})),t},this.addWindowLut=function(e){var t=e.getRescaleLut().getRSI();i[t.toString()]=e},this.getWindowPresets=function(){return r},this.getWindowPresetsNames=function(){return Object.keys(r)},this.setWindowPresets=function(e){r=e},this.setDefaultColourMap=function(e){o=e},this.addWindowPresets=function(e){for(var t,n=Object.keys(e),i=0;i<n.length;++i)if(t=n[i],void 0!==r[t]){if(void 0!==r[t].perslice&&!0===r[t].perslice)throw new Error("Cannot add perslice preset");r[t]=e[t]}else r[t]=e[t],S({type:"wlpresetadd",name:t})},this.getColourMap=function(){return o},this.setColourMap=function(e){o=e,S({type:"colourchange",wc:this.getCurrentWindowLut().getWindowLevel().getCenter(),ww:this.getCurrentWindowLut().getWindowLevel().getWidth()})},this.getCurrentPosition=function(){return x},this.getCurrentIndex=function(){var e=this.getCurrentPosition();return e?this.getImage().getGeometry().worldToIndex(e):null},this.canSetPosition=function(e){var t=g.getGeometry(),e=t.worldToIndex(e),n=[this.getScrollIndex()];return 4===e.length()&&n.push(3),t.isIndexInBounds(e,n)},this.getOrigin=function(e){var t=g.getGeometry(),n=0;return void 0!==e&&(n=t.worldToIndex(e).get(2)),t.getOrigins()[n]},this.setCurrentPosition=function(e,t){var n=g.getGeometry(),i=n.worldToIndex(e),r=[this.getScrollIndex()];return 4===i.length()&&r.push(3),n.isIndexInBounds(i,r)?this.setCurrentIndex(i,t):(t||S({type:"positionchange",value:[i.getValues(),e.getValues()],valid:!1}),!1)},this.setCurrentIndex=function(e,t){void 0===t&&(t=!1);var n=g.getGeometry(),i=n.indexToWorld(e),r=[this.getScrollIndex()];if(4===e.length()&&r.push(3),!n.isIndexInBounds(e,r))return!1;var o=null,a=null;if(a=this.getCurrentPosition()?this.getCurrentIndex():a)if(a.canCompare(e))o=a.compare(e);else{for(var o=[],s=Math.min(a.length(),e.length()),u=0;u<s;++u)a.get(u)!==e.get(u)&&o.push(u);for(var l=Math.max(a.length(),e.length()),c=s;c<l;++c)o.push(c)}else{o=[];for(var d=0;d<e.length();++d)o.push(d)}return x=i,t||(n={type:"positionchange",value:[e.getValues(),i.getValues()],diffDims:o,data:{imageUid:g.getImageUid(e)}},g.canQuantify()&&(r=g.getRescaledValueAtIndex(e),n.value.push(r)),S(n)),!0},this.setWindowLevel=function(e,t,n,i){var r,o,a;t<1||(void 0===n&&(n="manual"),void 0===i&&(i=!1),(r=new _.image.WindowLevel(e,t)).equals(u)||(o=!u||u.getWidth()!==t,a=!u||u.getCenter()!==e,u=r,s=n,(o||a)&&S({type:"wlchange",value:[e,t],wc:e,ww:t,skipGenerate:i})))},this.setWindowLevelPreset=function(e,t){var n=this.getWindowPresets()[e];if(void 0===n)throw new Error("Unknown window level preset: '"+e+"'");"minmax"===e&&void 0===n.wl&&(n.wl=[this.getWindowLevelMinMax()]);var i,r=n.wl[0];void 0!==n.perslice&&!0===n.perslice&&(i=g.getSecondaryOffset(this.getCurrentIndex()),r=n.wl[i]),this.setWindowLevel(r.getCenter(),r.getWidth(),e,t)},this.setWindowLevelPresetById=function(e,t){var n=Object.keys(this.getWindowPresets());this.setWindowLevelPreset(n[e],t)},this.clone=function(){var e,t=new _.image.View(this.getImage());for(e in i)t.addWindowLut(i[e]);return t.setListeners(this.getListeners()),t},this.addEventListener=function(e,t){a.add(e,t)},this.removeEventListener=function(e,t){a.remove(e,t)}},_.image.View.prototype.getWindowLevelMinMax=function(){var e=this.getImage().getRescaledDataRange(),t=e.min,e=e.max-t,t=(e<1&&(_.logger.warn("Zero or negative window width, defaulting to one."),e=1),t+e/2);return new _.image.WindowLevel(t,e)},_.image.View.prototype.setWindowLevelMinMax=function(){var e=this.getWindowLevelMinMax();this.setWindowLevel(e.getCenter(),e.getWidth(),"minmax")},_.image.View.prototype.generateImageData=function(e,t){void 0===t&&(this.getCurrentIndex()||this.setInitialIndex(),t=this.getCurrentIndex());var n=this.getImage(),i=_.image.getSliceIterator(n,t,!1,this.getOrientation()),r=n.getPhotometricInterpretation();switch(r){case"MONOCHROME1":case"MONOCHROME2":_.image.generateImageDataMonochrome(e,i,this.getAlphaFunction(),this.getCurrentWindowLut(),this.getColourMap());break;case"PALETTE COLOR":_.image.generateImageDataPaletteColor(e,i,this.getAlphaFunction(),this.getColourMap(),16===n.getMeta().BitsStored);break;case"RGB":_.image.generateImageDataRgb(e,i,this.getAlphaFunction(),this.getCurrentWindowLut());break;case"YBR_FULL":_.image.generateImageDataYbrFull(e,i,this.getAlphaFunction());break;default:throw new Error("Unsupported photometric interpretation: "+r)}},_.image.View.prototype.incrementIndex=function(e,t){var n=this.getCurrentIndex(),i=new Array(n.length()),e=(i.fill(0),e<i.length?i[e]=1:console.warn("Cannot increment given index: ",e,i.length),new _.math.Index(i)),i=n.add(e);return this.setCurrentIndex(i,t)},_.image.View.prototype.decrementIndex=function(e,t){var n=this.getCurrentIndex(),i=new Array(n.length()),e=(i.fill(0),e<i.length?i[e]=-1:console.warn("Cannot decrement given index: ",e,i.length),new _.math.Index(i)),i=n.add(e);return this.setCurrentIndex(i,t)},_.image.View.prototype.getScrollIndex=function(){var e=this.getOrientation();return void 0!==e?e.getThirdColMajorDirection():2},_.image.View.prototype.decrementScrollIndex=function(e){return this.decrementIndex(this.getScrollIndex(),e)},_.image.View.prototype.incrementScrollIndex=function(e){return this.incrementIndex(this.getScrollIndex(),e)},_||{}),_=(_.image=_.image||{},_.image.ViewFactory=function(){},_.ViewFactory=_.image.ViewFactory,_.image.ViewFactory.prototype.create=function(e,t){var n,i=new _.image.View(t),r=("MONOCHROME1"===t.getPhotometricInterpretation()?i.setDefaultColourMap(_.image.lut.invPlain):"PALETTE COLOR"===t.getPhotometricInterpretation()&&void 0!==(n=t.getMeta().paletteLut)&&i.setDefaultColourMap(n),{});if((r=void 0!==t.getMeta().windowPresets?t.getMeta().windowPresets:r).minmax={name:"minmax"},void 0!==_.tool&&void 0!==_.tool.defaultpresets){var o,a=t.getMeta().Modality;for(o in _.tool.defaultpresets[a]){var s=_.tool.defaultpresets[a][o];r[o]={wl:[new _.image.WindowLevel(s.center,s.width)],name:o}}}return i.setWindowPresets(r),i.init(),i},_||{}),_=(_.image=_.image||{},_.image.generateImageDataMonochrome=function(e,t,n,i,r){for(var o,a=0,s=t.next();!s.done;)o=i.getValue(s.value),e.data[a]=r.red[o],e.data[a+1]=r.green[o],e.data[a+2]=r.blue[o],e.data[a+3]=n(s.value,s.index),a+=4,s=t.next()},_||{}),_=(_.image=_.image||{},_.image.generateImageDataPaletteColor=function(e,t,n,i,r){r&&_.logger.info("Scaling 16bits data to 8bits.");for(var o,a=0,s=t.next();!s.done;)o=s.value,r?(e.data[a]=i.red[o]>>8,e.data[a+1]=i.green[o]>>8,e.data[a+2]=i.blue[o]>>8):(e.data[a]=i.red[o],e.data[a+1]=i.green[o],e.data[a+2]=i.blue[o]),e.data[a+3]=n(o,s.index),a+=4,s=t.next()},_||{}),_=(_.image=_.image||{},_.image.generateImageDataRgb=function(e,t,n){for(var i=0,r=t.next();!r.done;)e.data[i]=r.value[0],e.data[i+1]=r.value[1],e.data[i+2]=r.value[2],e.data[i+3]=n(r.value,r.index),i+=4,r=t.next()},_||{}),_=(_.image=_.image||{},_.image.generateImageDataYbrFull=function(e,t,n){for(var i,r=0,o=t.next();!o.done;)i=_.utils.ybrToRgb(o.value[0],o.value[1],o.value[2]),e.data[r]=i.r,e.data[r+1]=i.g,e.data[r+2]=i.b,e.data[r+3]=n(o.value,o.index),r+=4,o=t.next()},_||{}),_=(_.image=_.image||{},_.image.MinWindowWidth=1,_.image.validateWindowWidth=function(e){return e<_.image.MinWindowWidth?_.image.MinWindowWidth:e},_.image.WindowLevel=function(t,n){if(n<_.image.MinWindowWidth)throw new Error("Window width shall always be greater than or equal to "+_.image.MinWindowWidth);var i=0,r=0,o=255,a=null,s=null,u=null,l=null;function c(){var e=t+i;a=e-.5-(n-1)/2,s=e-.5+(n-1)/2,u=(o-r)/(n-1),l=(-(e-.5)/(n-1)+.5)*(o-r)+r}c(),this.getCenter=function(){return t},this.getWidth=function(){return n},this.setRange=function(e,t){r=parseInt(e,10),o=parseInt(t,10),c()},this.setSignedOffset=function(e){i=e,c()},this.apply=function(e){return e<=a?r:s<e?o:parseInt(e*u+l,10)}},_.image.WindowLevel.prototype.equals=function(e){return null!==e&&this.getCenter()===e.getCenter()&&this.getWidth()===e.getWidth()},_.image.WindowLevel.prototype.toString=function(){return this.getCenter()+", "+this.getWidth()},_||{}),_=(_.image=_.image||{},_.image.WindowLut=function(n,t){var i=null,r=null,o=!1,a=0;this.getWindowLevel=function(){return r},this.isSigned=function(){return t},this.getRescaleLut=function(){return n},this.isReady=function(){return o},this.setWindowLevel=function(e){a=0,(r=e).setSignedOffset(0),t&&(e=n.getLength(),a=e/2,r.setSignedOffset(n.getRSI().getSlope()*a)),o=!1},this.update=function(){if(!o){n.isReady()||n.initialise();var e=n.getLength();i=i||new Uint8ClampedArray(e);for(var t=0;t<e;++t)i[t]=r.apply(n.getValue(t));o=!0}},this.getLength=function(){return i.length},this.getValue=function(e){return i[e+a]}},_||{}),_=(_.io=_.io||{},_.io.DicomDataLoader=function(){var i=this,r={},o=!1,a=(this.setOptions=function(e){r=e},this.isLoading=function(){return o},new _.image.DicomBufferToView);this.load=function(e,t,n){o||(a.setOptions(r),a.onloadstart=i.onloadstart,a.onprogress=i.onprogress,a.onloaditem=i.onloaditem,a.onload=i.onload,a.onloadend=function(e){o=!1,i.onloadend(e)},a.onerror=i.onerror,a.onabort=i.onabort),o=!0,a.convert(e,t,n)},this.abort=function(){o=!1,a.abort()}},_.io.DicomDataLoader.prototype.canLoadFile=function(e){e=_.utils.getFileExtension(e.name);return null===e||"dcm"===e},_.io.DicomDataLoader.prototype.canLoadUrl=function(e,t){if(void 0!==t&&void 0!==t.requestHeaders)return void 0!==t.requestHeaders.find(function(e){return"Accept"===e.name&&_.utils.startsWith(e.value,"application/dicom")&&"+"!==e.value[18]});var t=_.utils.getUrlFromUri(e),e=_.utils.getFileExtension(t.pathname),n=null===e,e="dcm"===e,t=t.searchParams.get("contentType");return null!=t?"application/dicom"===t:n||e},_.io.DicomDataLoader.prototype.canLoadMemory=function(e){return void 0!==e["Content-Type"]&&"application/dicom"===e["Content-Type"]||void 0!==e.filename&&this.canLoadFile(e.filename)},_.io.DicomDataLoader.prototype.loadFileAs=function(){return _.io.fileContentTypes.ArrayBuffer},_.io.DicomDataLoader.prototype.loadUrlAs=function(){return _.io.urlContentTypes.ArrayBuffer},_.io.DicomDataLoader.prototype.onloadstart=function(e){},_.io.DicomDataLoader.prototype.onprogress=function(e){},_.io.DicomDataLoader.prototype.onloaditem=function(e){},_.io.DicomDataLoader.prototype.onload=function(e){},_.io.DicomDataLoader.prototype.onloadend=function(e){},_.io.DicomDataLoader.prototype.onerror=function(e){},_.io.DicomDataLoader.prototype.onabort=function(e){},_.io.loaderList=_.io.loaderList||[],_.io.loaderList.push("DicomDataLoader"),_||{}),_=(_.io=_.io||{},_.io.fileContentTypes={Text:0,ArrayBuffer:1,DataURL:2},_.io.FilesLoader=function(){var t,c=this,n=null,d=[],g=null,i=0,r=0;function x(e){n=e,r=i=0,d=[],g=null}function S(e){c.onloaditem(e),m()}function m(e){++i===n.length&&c.onload({source:n})}function h(e){++r===2*n.length&&c.onloadend({source:n})}function f(t,n){return function(e){e.source=n,t(e)}}this.getDefaultCharacterSet=function(){return t},this.setDefaultCharacterSet=function(e){t=e},this.load=function(e){if(void 0!==e&&0!==e.length){x(e),this.onloadstart({source:e});for(var t=new _.utils.MultiProgressHandler(c.onprogress),n=(t.setNToLoad(e.length),[]),i=0;i<_.io.loaderList.length;++i)n.push(new _.io[_.io.loaderList[i]]);for(var r=e[0],o=null,a=!1,s=0;s<n.length;++s)if((o=n[s]).canLoadFile(r)){a=!0,o.setOptions({numberOfFiles:e.length,defaultCharacterSet:this.getDefaultCharacterSet()}),o.onprogress=t.getUndefinedMonoProgressHandler(1),void 0===o.onloaditem?o.onload=S:(o.onloaditem=c.onloaditem,o.onload=m),o.onloadend=h,o.onerror=c.onerror,o.onabort=c.onabort,g=o;break}if(!a)throw new Error("No loader found for file: "+r.name);for(var u=0;u<e.length;++u){if(r=e[u],!o.canLoadFile(r))throw new Error("Input file of different type: "+r);var l=new FileReader;d.push(l),l.onprogress=f(t.getMonoProgressHandler(u,0),r),l.onload=function(t,n,i){return function(e){t.load(e.target.result,n,i)}}(o,r,u),l.onloadend=h,l.onerror=f(c.onerror,r),l.onabort=f(c.onabort,r),o.loadFileAs()===_.io.fileContentTypes.Text?l.readAsText(r):o.loadFileAs()===_.io.fileContentTypes.DataURL?l.readAsDataURL(r):o.loadFileAs()===_.io.fileContentTypes.ArrayBuffer&&l.readAsArrayBuffer(r)}}},this.abort=function(){for(var e=0;e<d.length;++e)1===d[e].readyState&&d[e].abort();g&&g.isLoading()&&g.abort()}},_.io.FilesLoader.prototype.onloadstart=function(e){},_.io.FilesLoader.prototype.onprogress=function(e){},_.io.FilesLoader.prototype.onloaditem=function(e){},_.io.FilesLoader.prototype.onload=function(e){},_.io.FilesLoader.prototype.onloadend=function(e){},_.io.FilesLoader.prototype.onerror=function(e){},_.io.FilesLoader.prototype.onabort=function(e){},_||{}),_=(_.io=_.io||{},_.io.JSONTextLoader=function(){var i=this,r=!1;this.setOptions=function(e){},this.isLoading=function(){return r},this.load=function(e,t,n){r=!0,i.onloadstart({source:t});try{i.onprogress({lengthComputable:!0,loaded:100,total:100,index:n,source:t}),i.onload({data:e,source:t})}catch(e){i.onerror({error:e,source:t})}finally{r=!1,i.onloadend({source:t})}},this.abort=function(){r=!1,i.onabort({}),i.onloadend({})}},_.io.JSONTextLoader.prototype.canLoadFile=function(e){return"json"===_.utils.getFileExtension(e.name)},_.io.JSONTextLoader.prototype.canLoadUrl=function(e,t){if(void 0!==t&&void 0!==t.requestHeaders)return void 0!==t.requestHeaders.find(function(e){return"Accept"===e.name&&_.utils.startsWith(e.value,"application/json")&&_.utils.startsWith(e.value,"application/dicom+json")});t=_.utils.getUrlFromUri(e);return"json"===_.utils.getFileExtension(t.pathname)},_.io.JSONTextLoader.prototype.canLoadMemory=function(e){return!(void 0===e["Content-Type"]||!e["Content-Type"].includes("json"))||void 0!==e.filename&&this.canLoadFile(e.filename)},_.io.JSONTextLoader.prototype.loadFileAs=function(){return _.io.fileContentTypes.Text},_.io.JSONTextLoader.prototype.loadUrlAs=function(){return _.io.urlContentTypes.Text},_.io.JSONTextLoader.prototype.onloadstart=function(e){},_.io.JSONTextLoader.prototype.onprogress=function(e){},_.io.JSONTextLoader.prototype.onload=function(e){},_.io.JSONTextLoader.prototype.onloadend=function(e){},_.io.JSONTextLoader.prototype.onerror=function(e){},_.io.JSONTextLoader.prototype.onabort=function(e){},_.io.loaderList=_.io.loaderList||[],_.io.loaderList.push("JSONTextLoader"),_||{}),_=(_.io=_.io||{},_.io.MemoryLoader=function(){var t,l=this,n=null,c=null,i=0,r=0;function d(e){n=e,r=i=0,c=null}function g(e){l.onloaditem(e),x()}function x(e){++i===n.length&&l.onload({source:n})}function S(e){++r===n.length&&l.onloadend({source:n})}this.getDefaultCharacterSet=function(){return t},this.setDefaultCharacterSet=function(e){t=e},this.load=function(e){if(void 0!==e&&0!==e.length){d(e),this.onloadstart({source:e});for(var t=new _.utils.MultiProgressHandler(l.onprogress),n=(t.setNToLoad(e.length),t.setNumberOfDimensions(1),[]),i=0;i<_.io.loaderList.length;++i)n.push(new _.io[_.io.loaderList[i]]);for(var r=e[0],o=null,a=!1,s=0;s<n.length;++s)if((o=n[s]).canLoadMemory(r)){a=!0,o.setOptions({numberOfFiles:e.length,defaultCharacterSet:this.getDefaultCharacterSet()}),o.onprogress=t.getUndefinedMonoProgressHandler(0),void 0===o.onloaditem?o.onload=g:(o.onloaditem=l.onloaditem,o.onload=x),o.onloadend=S,o.onerror=l.onerror,o.onabort=l.onabort,c=o;break}if(!a)throw new Error("No loader found for data: "+r.filename);for(var u=0;u<e.length;++u){if(r=e[u],!o.canLoadMemory(r))throw new Error("Input data of different type: "+r.filename);o.load(r.data,r.filename,u)}}},this.abort=function(){c&&c.isLoading()&&c.abort()}},_.io.MemoryLoader.prototype.onloadstart=function(e){},_.io.MemoryLoader.prototype.onprogress=function(e){},_.io.MemoryLoader.prototype.onloaditem=function(e){},_.io.MemoryLoader.prototype.onload=function(e){},_.io.MemoryLoader.prototype.onloadend=function(e){},_.io.MemoryLoader.prototype.onerror=function(e){},_.io.MemoryLoader.prototype.onabort=function(e){},_||{}),_=(_.io=_.io||{},_.io.MultipartLoader=function(){var i=this,r=!1;this.setOptions=function(e){},this.isLoading=function(){return r},this.load=function(e,t,n){this.onloadstart({source:t}),r=!0;t=new _.io.MemoryLoader;t.onprogress=function(e){e.loaded=50+e.loaded/2,e.index=n,i.onprogress(e)},t.onloaditem=i.onloaditem,t.onload=i.onload,t.onloadend=function(e){r=!1,i.onloadend(e)},t.onerror=i.onerror,t.onabort=i.onabort,t.load(_.utils.parseMultipart(e))},this.abort=function(){r=!1,i.onabort({}),i.onloadend({})}},_.io.MultipartLoader.prototype.canLoadFile=function(e){return!1},_.io.MultipartLoader.prototype.canLoadUrl=function(e,t){return void 0!==t&&void 0!==t.requestHeaders&&void 0!==t.requestHeaders.find(function(e){return"Accept"===e.name&&_.utils.startsWith(e.value,"multipart/related")})},_.io.MultipartLoader.prototype.canLoadMemory=function(e){return!1},_.io.MultipartLoader.prototype.loadFileAs=function(){return _.io.fileContentTypes.ArrayBuffer},_.io.MultipartLoader.prototype.loadUrlAs=function(){return _.io.urlContentTypes.ArrayBuffer},_.io.MultipartLoader.prototype.onloadstart=function(e){},_.io.MultipartLoader.prototype.onprogress=function(e){},_.io.MultipartLoader.prototype.onloaditem=function(e){},_.io.MultipartLoader.prototype.onload=function(e){},_.io.MultipartLoader.prototype.onloadend=function(e){},_.io.MultipartLoader.prototype.onerror=function(e){},_.io.MultipartLoader.prototype.onabort=function(e){},_.io.loaderList=_.io.loaderList||[],_.io.loaderList.push("MultipartLoader"),_||{}),_=(_.io=_.io||{},_.io.RawImageLoader=function(){var a=this,s=!1;this.setOptions=function(e){},this.isLoading=function(){return!0},this.load=function(e,t,n){s=!1;var i,r,o=new Image;o.onload=function(){try{s||(a.onprogress({lengthComputable:!0,loaded:100,total:100,index:n,source:t}),a.onload(_.image.getViewFromDOMImage(this,t)))}catch(e){a.onerror({error:e,source:t})}finally{a.onloadend({source:t})}},o.origin=t,o.index=n,"string"==typeof t?(i=t.split(".").pop().toLowerCase(),o.src=((r=i=i)&&"jpg"!==i||(r="jpeg"),i=new Blob([e],{type:"image/"+r}),l.URL.createObjectURL(i))):o.src=e},this.abort=function(){s=!0,a.onabort({}),a.onloadend({})}},_.io.RawImageLoader.prototype.canLoadFile=function(e){return e.type.match("image.*")},_.io.RawImageLoader.prototype.canLoadUrl=function(e,t){if(void 0!==t&&void 0!==t.requestHeaders)return void 0!==t.requestHeaders.find(function(e){return"Accept"===e.name&&_.utils.startsWith(e.value,"image/")});t=_.utils.getUrlFromUri(e),e=_.utils.getFileExtension(t.pathname),e="jpeg"===e||"jpg"===e||"png"===e||"gif"===e,t=t.searchParams.get("contentType");return null!=t?"image/jpeg"===t||"image/png"===t||"image/gif"===t:e},_.io.RawImageLoader.prototype.canLoadMemory=function(e){return void 0!==e.filename&&this.canLoadFile(e.filename)},_.io.RawImageLoader.prototype.loadFileAs=function(){return _.io.fileContentTypes.DataURL},_.io.RawImageLoader.prototype.loadUrlAs=function(){return _.io.urlContentTypes.ArrayBuffer},_.io.RawImageLoader.prototype.onloadstart=function(e){},_.io.RawImageLoader.prototype.onprogress=function(e){},_.io.RawImageLoader.prototype.onload=function(e){},_.io.RawImageLoader.prototype.onloadend=function(e){},_.io.RawImageLoader.prototype.onerror=function(e){},_.io.RawImageLoader.prototype.onabort=function(e){},_.io.loaderList=_.io.loaderList||[],_.io.loaderList.push("RawImageLoader"),_||{}),_=(_.io=_.io||{},_.io.RawVideoLoader=function(){var o=this;this.setOptions=function(e){},this.isLoading=function(){return!0},this.load=function(e,t,n){var i,r=document.createElement("video");"string"==typeof t?(i=t.split(".").pop().toLowerCase(),r.src=function(e,t){for(var n=new Uint8Array(e),i="",r=0;r<n.byteLength;++r)i+=String.fromCharCode(n[r]);return"data:video/"+t+";base64,"+l.btoa(i)}(e,i)):r.src=e,r.file=t,r.index=n,r.onloadedmetadata=function(){try{_.image.getViewFromDOMVideo(this,o.onloaditem,o.onload,o.onprogress,o.onloadend,n,t)}catch(e){o.onerror({error:e,source:t}),o.onloadend({source:t})}}},this.abort=function(){o.onabort({}),o.onloadend({})}},_.io.RawVideoLoader.prototype.canLoadFile=function(e){return e.type.match("video.*")},_.io.RawVideoLoader.prototype.canLoadUrl=function(e,t){if(void 0!==t&&void 0!==t.requestHeaders)return void 0!==t.requestHeaders.find(function(e){return"Accept"===e.name&&_.utils.startsWith(e.value,"video/")});t=_.utils.getUrlFromUri(e),e=_.utils.getFileExtension(t.pathname);return"mp4"===e||"ogg"===e||"webm"===e},_.io.RawVideoLoader.prototype.canLoadMemory=function(e){return void 0!==e.filename&&this.canLoadFile(e.filename)},_.io.RawVideoLoader.prototype.loadFileAs=function(){return _.io.fileContentTypes.DataURL},_.io.RawVideoLoader.prototype.loadUrlAs=function(){return _.io.urlContentTypes.ArrayBuffer},_.io.RawVideoLoader.prototype.onloadstart=function(e){},_.io.RawVideoLoader.prototype.onprogress=function(e){},_.io.RawVideoLoader.prototype.onloaditem=function(e){},_.io.RawVideoLoader.prototype.onload=function(e){},_.io.RawVideoLoader.prototype.onloadend=function(e){},_.io.RawVideoLoader.prototype.onerror=function(e){},_.io.RawVideoLoader.prototype.onabort=function(e){},_.io.loaderList=_.io.loaderList||[],_.io.loaderList.push("RawVideoLoader"),_||{}),L=(_.io=_.io||{},L||{}),_=(_.io.State=function(){this.toJSON=function(e){var t=e.getActiveLayerGroup(),n=t.getActiveViewLayer().getViewController(),i=n.getCurrentIndex(),t=t.getActiveDrawLayer(),r=t.getDrawController();return JSON.stringify({version:"0.5","window-center":n.getWindowLevel().center,"window-width":n.getWindowLevel().width,position:i.getValues(),scale:e.getAddedScale(),offset:e.getOffset(),drawings:t.getKonvaLayer().toObject(),drawingsDetails:r.getDrawStoreDetails()})},this.fromJSON=function(e){var t,n,i,e=JSON.parse(e),r=null;if("0.1"===e.version)n=e,i=_.io.v01Tov02DrawingsAndDetails(n.drawings),n.drawings=_.io.v02Tov03Drawings(i.drawings).toObject(),n.drawingsDetails=_.io.v03Tov04DrawingsDetails(i.drawingsDetails),(n=_.io.v04Tov05Data(n)).drawings=_.io.v04Tov05Drawings(n.drawings),r=n;else if("0.2"===e.version)(i=e).drawings=_.io.v02Tov03Drawings(i.drawings).toObject(),i.drawingsDetails=_.io.v03Tov04DrawingsDetails(_.io.v02Tov03DrawingsDetails(i.drawingsDetails)),(i=_.io.v04Tov05Data(i)).drawings=_.io.v04Tov05Drawings(i.drawings),r=i;else if("0.3"===e.version)(n=e).drawingsDetails=_.io.v03Tov04DrawingsDetails(n.drawingsDetails),(n=_.io.v04Tov05Data(n)).drawings=_.io.v04Tov05Drawings(n.drawings),r=n;else if("0.4"===e.version)t=e,(t=_.io.v04Tov05Data(t)).drawings=_.io.v04Tov05Drawings(t.drawings),r=t;else{if("0.5"!==e.version)throw new Error("Unknown state file format version: '"+e.version+"'.");r=e}return r},this.apply=function(e,t){var n,i,r=e.getActiveLayerGroup().getActiveViewLayer().getViewController(),r=(r.setWindowLevel(t["window-center"],t["window-width"]),r.setCurrentIndex(new _.math.Index(t.position)),e.getActiveLayerGroup().getBaseScale()),o=null,a=null;a=void 0!==t.scaleCenter?(o={x:t.scale*r.x,y:t.scale*r.y,z:1},n=t.scaleCenter.x-t.scaleCenter.x*t.scale,i=t.scaleCenter.y-t.scaleCenter.y*t.scale,n=n+t.translation.x*o.x,i=i+t.translation.y*o.y,{x:-n/o.x,y:-i/o.y,z:0}):(o={x:t.scale.x*r.x,y:t.scale.y*r.y,z:r.z},{x:t.offset.x,y:t.offset.y,z:0}),e.getActiveLayerGroup().setScale(o),e.getActiveLayerGroup().setOffset(a),e.render(0),e.setDrawings(t.drawings,t.drawingsDetails)}},_.io.v02Tov03Drawings=function(e){for(var t,n,i=new L.Layer({listening:!1,visible:!0}),r="string"==typeof e?JSON.parse(e):e,o=0,a=r.length;o<a;++o)for(var s=0,u=r[o].length;s<u;++s)if(0!==(n=r[o][s]).length){for(var l=new L.Group({id:_.draw.getDrawPositionGroupId(new _.math.Index([1,1,o,s])),name:"position-group",visible:!1}),c=0,d=n.length;c<d;++c)(t=L.Node.create(n[c])).draggable(!0),t.getChildren().forEach(function(e){e.draggable(!1)}),l.add(t);i.add(l)}return i},_.io.v01Tov02DrawingsAndDetails=function(e){for(var t,n=[],i={},r=0,o=e.length;r<o;++r){n[r]=[];for(var a=0,s=e[r].length;a<s;++a){for(var u,l=[],c=0,d=(u=e[r][a]).length;c<d;++c){(t=L.Node.create(u[c])).visible(!0);var g={x:0,y:0},x=t.getChildren(function(e){return"shape"===e.name()})[0],S=(x.stroke(_.utils.colourNameToHex(x.stroke())),"line-group"===t.name()&&(t.name("ruler-group"),S=new L.Line({points:[x.points()[0],x.points()[1],x.points()[0],x.points()[1]],name:"shape-tick0"}),t.add(S),S=new L.Line({points:[x.points()[2],x.points()[3],x.points()[2],x.points()[3]],name:"shape-tick1"}),t.add(S)),t.getChildren(function(e){return"arc"===e.name()})),m=(1===S.length&&S[0].name("shape-arc"),t.getChildren(function(e){return"text"===e.name()})),h=new L.Text({name:"text",text:""}),m=(1===m.length?(g.x=m[0].x(),g.y=m[0].y(),m[0].remove(),h=m[0]):0!==x.points().length&&(g={x:x.points()[0],y:x.points()[1]}),new L.Label({x:g.x,y:g.y,name:"label"})),x=(m.add(h),m.add(new L.Tag),t.add(m),l.push(JSON.stringify(t.toObject())),h.text()),g=x.length,m=null;"ruler-group"===t.name()?(m={length:{value:parseFloat(x.substring(0,g-2)),unit:x.substring(-2)}},x="{length}"):"ellipse-group"===t.name()||"rectangle-group"===t.name()?(m={surface:{value:parseFloat(x.substring(0,g-3)),unit:x.substring(-3)}},x="{surface}"):"protractor-group"!==t.name()&&"rectangle-group"!==t.name()||(m={angle:{value:parseFloat(x.substring(0,g-1)),unit:x.substring(-1)}},x="{angle}"),i[t.id()]={textExpr:x,longText:"",quant:m}}n[r].push(l)}}return{drawings:n,drawingsDetails:i}},_.io.v02Tov03DrawingsDetails=function(e){for(var t={},n="string"==typeof e?JSON.parse(e):e,i=0,r=n.length;i<r;++i)for(var o=0,a=n[i].length;o<a;++o)for(var s=0,u=n[i][o].length;s<u;++s){var l=n[i][o][s];t[l.id]={textExpr:l.textExpr,longText:l.longText,quant:l.quant}}return t},_.io.v03Tov04DrawingsDetails=function(e){for(var t={},n=Object.keys(e),i=0,r=n.length;i<r;++i){var o=e[n[i]];t[n[i]]={meta:{textExpr:o.textExpr,longText:o.longText,quantification:o.quant}}}return t},_.io.v04Tov05Data=function(e){var t=e.position;return e.position=[t.i,t.j,t.k],e},_.io.v04Tov05Drawings=function(e){for(var t=e.children,n=0,i=t.length;n<i;++n){var r=t[n],o=r.attrs.id.split("_"),a=parseInt(o[0].substring(6),10),o=parseInt(o[1].substring(6),10),s="#2-";s+=0===a&&0!==o?o:a,r.attrs.id=s}return e},_||{}),_=(_.io=_.io||{},_.io.urlContentTypes={Text:0,ArrayBuffer:1},_.io.UrlsLoader=function(){var f,t,p=this,n=null,y=[],D=null,i=0,r=0;function v(e){n=e,r=i=0,f=!1,y=[],D=null}function C(e){p.onloaditem(e),T()}function T(e){++i===n.length&&p.onload({source:n})}function L(e){++r===2*n.length&&p.onloadend({source:n})}function I(t,n){return function(e){e.source=n,t(e)}}function u(e,t){if(void 0!==e&&0!==e.length){v(e);for(var n=new _.utils.MultiProgressHandler(p.onprogress),i=(n.setNToLoad(e.length),[]),r=0;r<_.io.loaderList.length;++r)i.push(new _.io[_.io.loaderList[r]]);for(var o=e[0],a=null,s=!1,u=0;u<i.length;++u)if((a=i[u]).canLoadUrl(o,t)){s=!0,a.setOptions({numberOfFiles:e.length,defaultCharacterSet:p.getDefaultCharacterSet()}),a.onprogress=n.getUndefinedMonoProgressHandler(1),void 0===a.onloaditem?a.onload=C:(a.onloaditem=p.onloaditem,a.onload=T),a.onloadend=L,a.onerror=p.onerror,a.onabort=p.onabort,D=a;break}if(!s)throw new Error("No loader found for url: "+o);function l(){L(),c<y.length-1&&!f&&y[++c].send(null)}for(var c=0,d=0;d<e.length;++d){if(o=e[d],!a.canLoadUrl(o,t))throw new Error("Input url of different type: "+o);var g=new XMLHttpRequest;if(g.open("GET",o,!0),void 0!==t){if(void 0!==t.requestHeaders)for(var x=t.requestHeaders,S=0;S<x.length;++S)void 0!==x[S].name&&void 0!==x[S].value&&g.setRequestHeader(x[S].name,x[S].value);void 0!==t.withCredentials&&(g.withCredentials=t.withCredentials)}g.onprogress=I(n.getMonoProgressHandler(d,0),o),g.onload=function(n,i,r){return function(e){var t=e.target.status;200!==t&&0!==t?(p.onerror({source:i,error:"GET "+e.target.responseURL+" "+e.target.status+" ("+e.target.statusText+")",target:e.target}),L()):n.load(e.target.response,i,r)}}(a,o,d),g.onloadend=l,g.onerror=I(p.onerror,o),g.onabort=I(p.onabort,o),a.loadUrlAs()===_.io.urlContentTypes.ArrayBuffer&&(g.responseType="arraybuffer"),y.push(g)}var m=y.length;void 0!==t&&void 0!==t.batchSize&&0!==m&&(m=Math.min(t.batchSize,y.length));for(var h=0;h<m;++h)f||y[c=h].send(null)}}this.getDefaultCharacterSet=function(){return t},this.setDefaultCharacterSet=function(e){t=e},this.load=function(e,t){var a,s,n;p.onloadstart({source:e}),1===e.length&&(_.utils.endsWith(e[0],"DICOMDIR")||_.utils.endsWith(e[0],".dcmdir"))?(a=e[0],s=t,(n=new XMLHttpRequest).open("GET",a,!0),n.responseType="arraybuffer",n.onload=function(e){var t=e.target.status;if(200!==t&&0!==t)return p.onerror({source:a,error:"GET "+e.target.responseURL+" "+e.target.status+" ("+e.target.statusText+")",target:e.target}),void p.onloadend({});for(var n=_.dicom.getFileListFromDicomDir(e.target.response)[0][0],i=_.utils.getRootPath(a),r=[],o=0;o<n.length;++o)r.push(i+"/"+n[o]);u(r,s)},n.onerror=function(e){I(p.onerror,a)(e),p.onloadend({})},n.onabort=function(e){I(p.onabort,a)(e),p.onloadend({})},n.send(null)):u(e,t)},this.abort=function(){f=!0;for(var e=0;e<y.length;++e)4!==y[e].readyState&&y[e].abort();D&&D.isLoading()&&D.abort()}},_.io.UrlsLoader.prototype.onloadstart=function(e){},_.io.UrlsLoader.prototype.onprogress=function(e){},_.io.UrlsLoader.prototype.onloaditem=function(e){},_.io.UrlsLoader.prototype.onload=function(e){},_.io.UrlsLoader.prototype.onloadend=function(e){},_.io.UrlsLoader.prototype.onerror=function(e){},_.io.UrlsLoader.prototype.onabort=function(e){},_||{}),i=(_.io=_.io||{},i||{}),_=(_.io.ZipLoader=function(){var r=this,o=!1,a=(this.setOptions=function(e){},this.isLoading=function(){return o},""),s=[],u=null;this.load=function(e,t,n){this.onloadstart({source:t}),o=!0,i.loadAsync(e).then(function(e){s=[],u=e.file(/.*\.dcm/);e=s.length;a=u[e].name,u[e].async("arrayBuffer").then(function(e){!function t(e,n,i){s.push({filename:a,data:e});e=100*s.length/u.length;r.onprogress({lengthComputable:!0,loaded:e/2,total:100,index:i,item:{loaded:e,total:100,source:n}}),s.length<u.length?(e=s.length,a=u[e].name,u[e].async("arrayBuffer").then(function(e){t(e,n,i)})):((e=new _.io.MemoryLoader).onprogress=function(e){e.loaded=50+e.loaded/2,e.index=i,r.onprogress(e)},e.onloaditem=r.onloaditem,e.onload=r.onload,e.onloadend=function(e){o=!1,r.onloadend(e)},e.onerror=r.onerror,e.onabort=r.onabort,e.load(s))}(e,t,n)})})},this.abort=function(){o=!1,r.onabort({}),r.onloadend({})}},_.io.ZipLoader.prototype.canLoadFile=function(e){return"zip"===_.utils.getFileExtension(e.name)},_.io.ZipLoader.prototype.canLoadUrl=function(e,t){if(void 0!==t&&void 0!==t.requestHeaders)return void 0!==t.requestHeaders.find(function(e){return"Accept"===e.name&&_.utils.startsWith(e.value,"application/zip")});t=_.utils.getUrlFromUri(e);return"zip"===_.utils.getFileExtension(t.pathname)},_.io.ZipLoader.prototype.canLoadMemory=function(e){return!1},_.io.ZipLoader.prototype.loadFileAs=function(){return _.io.fileContentTypes.ArrayBuffer},_.io.ZipLoader.prototype.loadUrlAs=function(){return _.io.urlContentTypes.ArrayBuffer},_.io.ZipLoader.prototype.onloadstart=function(e){},_.io.ZipLoader.prototype.onprogress=function(e){},_.io.ZipLoader.prototype.onloaditem=function(e){},_.io.ZipLoader.prototype.onload=function(e){},_.io.ZipLoader.prototype.onloadend=function(e){},_.io.ZipLoader.prototype.onerror=function(e){},_.io.ZipLoader.prototype.onabort=function(e){},_.io.loaderList=_.io.loaderList||[],_.io.loaderList.push("ZipLoader"),_||{}),_=(_.math=_.math||{},_.math.BucketQueue=function(e,t){this.bucketCount=1<<e,this.mask=this.bucketCount-1,this.size=0,this.loc=0,this.cost=void 0!==t?t:function(e){return e},this.buckets=this.buildArray(this.bucketCount)},_.math.BucketQueue.prototype.push=function(e){var t=this.getBucket(e);e.next=this.buckets[t],this.buckets[t]=e,this.size++},_.math.BucketQueue.prototype.pop=function(){if(0===this.size)throw new Error("Cannot pop, bucketQueue is empty.");for(;null===this.buckets[this.loc];)this.loc=(this.loc+1)%this.bucketCount;var e=this.buckets[this.loc];return this.buckets[this.loc]=e.next,e.next=null,this.size--,e},_.math.BucketQueue.prototype.remove=function(e){if(!e)return!1;for(var t=this.getBucket(e),n=this.buckets[t];null!==n&&(null===n.next||e.x!==n.next.x||e.y!==n.next.y);)n=n.next;return null!==n&&(n.next=n.next.next,this.size--,!0)},_.math.BucketQueue.prototype.isEmpty=function(){return 0===this.size},_.math.BucketQueue.prototype.getBucket=function(e){return this.cost(e)&this.mask},_.math.BucketQueue.prototype.buildArray=function(e){for(var t=new Array(e),n=0;n<t.length;n++)t[n]=null;return t},_||{}),_=(_.math=_.math||{},_.math.mulABC=function(e,t,n){return null!==t&&null!==n?e*t*n:null},_.math.Circle=function(e,t){this.getCenter=function(){return e},this.getRadius=function(){return t}},_.math.Circle.prototype.equals=function(e){return null!==e&&this.getCenter().equals(e.getCenter())&&this.getRadius()===e.getRadius()},_.math.Circle.prototype.getSurface=function(){return Math.PI*this.getRadius()*this.getRadius()},_.math.Circle.prototype.getWorldSurface=function(e,t){return _.math.mulABC(this.getSurface(),e,t)},_.math.Circle.prototype.getRound=function(){for(var e=this.getCenter().getX(),t=this.getCenter().getY(),n=this.getRadius(),i=Math.pow(n,2),r=t+n,o=[],a=t-n;a<r;++a){var s=i-Math.pow(a-t,2);Math.abs(s)<1e-7||((s=Math.sqrt(s))<.5||o.push([[Math.round(e-s),Math.round(a)],[Math.round(e+s),Math.round(a)]]))}return o},_.math.Circle.prototype.quantify=function(e,t){var n={},i=e.get2DSpacing(),i=this.getWorldSurface(i[0],i[1]);return null!==i&&(n.surface={value:i/100,unit:_.i18n("unit.cm2")}),e.canQuantifyImage()&&0!==(i=this.getRound()).length&&(e=e.getImageVariableRegionValues(i),i=_.math.getStats(e,t),n.min={value:i.getMin(),unit:""},n.max={value:i.getMax(),unit:""},n.mean={value:i.getMean(),unit:""},n.stdDev={value:i.getStdDev(),unit:""},void 0!==i.getMedian&&(n.median={value:i.getMedian(),unit:""}),void 0!==i.getP25&&(n.p25={value:i.getP25(),unit:""}),void 0!==i.getP75&&(n.p75={value:i.getP75(),unit:""})),n},_||{}),_=(_.math=_.math||{},_.math.mulABC=function(e,t,n){return null!==t&&null!==n?e*t*n:null},_.math.Ellipse=function(e,t,n){this.getCenter=function(){return e},this.getA=function(){return t},this.getB=function(){return n}},_.math.Ellipse.prototype.equals=function(e){return null!==e&&this.getCenter().equals(e.getCenter())&&this.getA()===e.getA()&&this.getB()===e.getB()},_.math.Ellipse.prototype.getSurface=function(){return Math.PI*this.getA()*this.getB()},_.math.Ellipse.prototype.getWorldSurface=function(e,t){return _.math.mulABC(this.getSurface(),e,t)},_.math.Ellipse.prototype.getRound=function(){for(var e=this.getCenter().getX(),t=this.getCenter().getY(),n=this.getA(),i=this.getB(),r=n/i,o=Math.pow(i,2),a=t+i,s=[],u=t-i;u<a;++u){var l=o-Math.pow(u-t,2);Math.abs(l)<1e-7||((l=r*Math.sqrt(l))<.5||s.push([[Math.round(e-l),Math.round(u)],[Math.round(e+l),Math.round(u)]]))}return s},_.math.Ellipse.prototype.quantify=function(e,t){var n={},i=e.get2DSpacing(),i=this.getWorldSurface(i[0],i[1]);return null!==i&&(n.surface={value:i/100,unit:_.i18n("unit.cm2")}),e.canQuantifyImage()&&0!==(i=this.getRound()).length&&(e=e.getImageVariableRegionValues(i),i=_.math.getStats(e,t),n.min={value:i.getMin(),unit:""},n.max={value:i.getMax(),unit:""},n.mean={value:i.getMean(),unit:""},n.stdDev={value:i.getStdDev(),unit:""},void 0!==i.getMedian&&(n.median={value:i.getMedian(),unit:""}),void 0!==i.getP25&&(n.p25={value:i.getP25(),unit:""}),void 0!==i.getP75&&(n.p75={value:i.getP75(),unit:""})),n},_.math.getEllipseIndices=function(e,t,n){for(var i=e.getValues(),r=i.slice(),o=[],e=t[0],a=t[1],s=e/a,u=Math.pow(a,2),l=n[0],c=n[1],d=0;d<a;++d)for(var g=Math.round(s*Math.sqrt(u-Math.pow(d,2))),x=i[c]+d,S=i[c]-d,m=0;m<g;++m){var h=i[l]+m,f=i[l]-m;r[l]=h,r[c]=x,o.push(new _.math.Index(r.slice())),S!==x&&(r[c]=S,o.push(new _.math.Index(r.slice()))),f!==h&&(r[l]=f,r[c]=x,o.push(new _.math.Index(r.slice())),S!==x&&(r[c]=S,o.push(new _.math.Index(r.slice()))))}return o},_||{}),_=(_.math=_.math||{},_.math.Index=function(t){if(!t||void 0===t)throw new Error("Cannot create index with no values.");if(0===t.length)throw new Error("Cannot create index with empty values.");if(!t.every(function(e){return!isNaN(e)}))throw new Error("Cannot create index with non number values.");this.get=function(e){return t[e]},this.length=function(){return t.length},this.toString=function(){return"("+t.toString()+")"},this.getValues=function(){return t.slice()}},_.math.Index.prototype.canCompare=function(e){return!!e&&this.length()===e.length()},_.math.Index.prototype.equals=function(e){if(!this.canCompare(e))return!1;for(var t=0,n=this.length();t<n;++t)if(this.get(t)!==e.get(t))return!1;return!0},_.math.Index.prototype.compare=function(e){if(!this.canCompare(e))return null;for(var t=[],n=0,i=this.length();n<i;++n)this.get(n)!==e.get(n)&&t.push(n);return t},_.math.Index.prototype.add=function(e){if(!this.canCompare(e))return null;for(var t=[],n=0,i=this.length();n<i;++n)t.push(this.get(n)+e.get(n));return new _.math.Index(t)},_.math.Index.prototype.getWithNew2D=function(e,t){for(var n=[e,t],i=2,r=this.length();i<r;++i)n.push(this.get(i));return new _.math.Index(n)},_.math.getZeroIndex=function(e){e=new Array(e);return e.fill(0),new _.math.Index(e)},_.math.getIndexCompareFunction=function(n){return function(e,t){return e.get(n)-t.get(n)}},_.math.Index.prototype.toStringId=function(e){if(void 0===e){e=[];for(var t=0;t<this.length();++t)e.push(t)}for(var n=0;n<e.length;++n)if(e[n]>=this.length())throw new Error("Non valid dimension for toStringId.");for(var i="",r=0;r<e.length;++r)0!==r&&(i+="_"),i+="#"+e[r]+"-"+this.get(e[r]);return i},_.math.getIndexFromStringId=function(e){for(var t=e.split("_"),n=0,i=0;i<t.length;++i)n<(a=parseInt(t[i].substring(1,2),10))&&(n=a);if(0===n)throw new Error("No dimension found in point stringId");var r=new Array(n);r.fill(0);for(var o=0;o<t.length;++o){var a=parseInt(t[o].substring(1,3),10),s=parseInt(t[o].substring(3),10);r[a]=s}return new _.math.Point(r)},_||{}),_=(_.math=_.math||{},_.math.Line=function(e,t){this.getBegin=function(){return e},this.getEnd=function(){return t}},_.math.Line.prototype.equals=function(e){return null!==e&&this.getBegin().equals(e.getBegin())&&this.getEnd().equals(e.getEnd())},_.math.Line.prototype.getDeltaX=function(){return this.getEnd().getX()-this.getBegin().getX()},_.math.Line.prototype.getDeltaY=function(){return this.getEnd().getY()-this.getBegin().getY()},_.math.Line.prototype.getLength=function(){return Math.sqrt(this.getDeltaX()*this.getDeltaX()+this.getDeltaY()*this.getDeltaY())},_.math.Line.prototype.getWorldLength=function(e,t){var n=null;return null!==e&&null!==t&&(e=this.getDeltaX()*e,t=this.getDeltaY()*t,n=Math.sqrt(e*e+t*t)),n},_.math.Line.prototype.getMidpoint=function(){return new _.math.Point2D(parseInt((this.getBegin().getX()+this.getEnd().getX())/2,10),parseInt((this.getBegin().getY()+this.getEnd().getY())/2,10))},_.math.Line.prototype.getSlope=function(){return this.getDeltaY()/this.getDeltaX()},_.math.Line.prototype.getIntercept=function(){return(this.getEnd().getX()*this.getBegin().getY()-this.getBegin().getX()*this.getEnd().getY())/this.getDeltaX()},_.math.Line.prototype.getInclination=function(){return 180-180*Math.atan2(this.getDeltaY(),this.getDeltaX())/Math.PI},_.math.getAngle=function(e,t){var n=e.getDeltaX(),e=e.getDeltaY(),i=t.getDeltaX(),t=t.getDeltaY();return 360-(180-180*Math.atan2(n*t-e*i,n*i+e*t)/Math.PI)},_.math.getPerpendicularLine=function(e,t,n){var i,r,o=0,a=0,s=0,u=0;return u=0!==e.getSlope()?(e=-1/e.getSlope(),i=t.getY()-e*t.getX(),r=n/(2*Math.sqrt(1+e*e)),a=e*(o=t.getX()-r)+i,e*(s=t.getX()+r)+i):(o=t.getX(),a=t.getY()-n/2,s=t.getX(),t.getY()+n/2),new _.math.Line(new _.math.Point2D(o,a),new _.math.Point2D(s,u))},_.math.Line.prototype.quantify=function(e){var t={},e=e.get2DSpacing(),e=this.getWorldLength(e[0],e[1]);return null!==e&&(t.length={value:e,unit:_.i18n("unit.mm")}),t},_||{}),_=(_.math=_.math||{},void 0===Number.EPSILON&&(Number.EPSILON=Math.pow(2,-52)),_.math.BIG_EPSILON=1e4*Number.EPSILON,_.math.REAL_WORLD_EPSILON=1e-4,_.math.isSimilar=function(e,t,n){return void 0===n&&(n=Number.EPSILON),Math.abs(e-t)<n},_.math.Matrix33=function(n){var e=null;this.get=function(e,t){return n[3*e+t]},this.getInverse=function(){return e=null===e?_.math.getMatrixInverse(this):e}},_.math.Matrix33.prototype.equals=function(e,t){for(var n=0;n<3;++n)for(var i=0;i<3;++i)if(!_.math.isSimilar(this.get(n,i),e.get(n,i),t))return!1;return!0},_.math.Matrix33.prototype.toString=function(){for(var e="[",t=0;t<3;++t){0!==t&&(e+=", \n ");for(var n=0;n<3;++n)0!==n&&(e+=", "),e+=this.get(t,n)}return e+="]"},_.math.Matrix33.prototype.multiply=function(e){for(var t=[],n=0;n<3;++n)for(var i=0;i<3;++i){for(var r=0,o=0;o<3;++o)r+=this.get(n,o)*e.get(o,i);t.push(r)}return new _.math.Matrix33(t)},_.math.Matrix33.prototype.getAbs=function(){for(var e=[],t=0;t<3;++t)for(var n=0;n<3;++n)e.push(Math.abs(this.get(t,n)));return new _.math.Matrix33(e)},_.math.Matrix33.prototype.multiplyArray3D=function(e){if(3!==e.length)throw new Error("Cannot multiply 3x3 matrix with non 3D array: ",e.length);for(var t=[],n=0;n<3;++n){for(var i=0,r=0;r<3;++r)i+=this.get(n,r)*e[r];t.push(i)}return t},_.math.Matrix33.prototype.multiplyVector3D=function(e){e=this.multiplyArray3D([e.getX(),e.getY(),e.getZ()]);return new _.math.Vector3D(e[0],e[1],e[2])},_.math.Matrix33.prototype.multiplyPoint3D=function(e){e=this.multiplyArray3D([e.getX(),e.getY(),e.getZ()]);return new _.math.Point3D(e[0],e[1],e[2])},_.math.Matrix33.prototype.multiplyIndex3D=function(e){e=this.multiplyArray3D(e.getValues());return new _.math.Index(e)},_.math.getMatrixInverse=function(e){var t=e.get(0,0),n=e.get(0,1),i=e.get(0,2),r=e.get(1,0),o=e.get(1,1),a=e.get(1,2),s=e.get(2,0),u=e.get(2,1),e=e.get(2,2),l=o*e-a*u,c=a*s-r*e,d=r*u-o*s,g=t*l+n*c+i*d;{if(0!=g)return new _.math.Matrix33([(g=1/g)*l,g*(i*u-n*e),g*(n*a-i*o),g*c,g*(t*e-i*s),g*(i*r-t*a),g*d,g*(n*s-t*u),g*(t*o-n*r)]);_.logger.warn("Cannot invert 3*3 matrix with zero determinant.")}},_.math.Matrix33.prototype.getRowAbsMax=function(e){var t=[Math.abs(this.get(e,0)),Math.abs(this.get(e,1)),Math.abs(this.get(e,2))],n=Math.max.apply(null,t),t=t.indexOf(n);return{value:this.get(e,t),index:t}},_.math.Matrix33.prototype.getColAbsMax=function(e){var t=[Math.abs(this.get(0,e)),Math.abs(this.get(1,e)),Math.abs(this.get(2,e))],n=Math.max.apply(null,t),t=t.indexOf(n);return{value:this.get(t,e),index:t}},_.math.Matrix33.prototype.asOneAndZeros=function(){for(var e=[],t=0;t<3;++t)for(var n=this.getRowAbsMax(t),i=0<n.value?1:-1,r=0;r<3;++r)r===n.index?e.push(i):e.push(0);return new _.math.Matrix33(e)},_.math.Matrix33.prototype.getThirdColMajorDirection=function(){return this.getColAbsMax(2).index},_.math.getIdentityMat33=function(){return new _.math.Matrix33([1,0,0,0,1,0,0,0,1])},_.math.isIdentityMat33=function(e){return e.equals(_.math.getIdentityMat33())},_.math.getCoronalMat33=function(){return new _.math.Matrix33([1,0,0,0,0,1,0,-1,0])},_.math.getSagittalMat33=function(){return new _.math.Matrix33([0,0,-1,1,0,0,0,-1,0])},_.math.getMatrixFromName=function(e){var t=null;return"axial"===e?t=_.math.getIdentityMat33():"coronal"===e?t=_.math.getCoronalMat33():"sagittal"===e&&(t=_.math.getSagittalMat33()),t},_||{}),_=(_.math=_.math||{},_.math.Path=function(e,t){this.pointArray=e?e.slice():[],this.controlPointIndexArray=t?t.slice():[]},_.math.Path.prototype.getPoint=function(e){return this.pointArray[e]},_.math.Path.prototype.isControlPoint=function(e){e=this.pointArray.indexOf(e);if(-1!==e)return-1!==this.controlPointIndexArray.indexOf(e);throw new Error("Error: isControlPoint called with not in list point.")},_.math.Path.prototype.getLength=function(){return this.pointArray.length},_.math.Path.prototype.addPoint=function(e){this.pointArray.push(e)},_.math.Path.prototype.addControlPoint=function(e){e=this.pointArray.indexOf(e);if(-1===e)throw new Error("Cannot mark a non registered point as control point.");this.controlPointIndexArray.push(e)},_.math.Path.prototype.addPoints=function(e){this.pointArray=this.pointArray.concat(e)},_.math.Path.prototype.appenPath=function(e){for(var t=this.pointArray.length,n=(this.pointArray=this.pointArray.concat(e.pointArray),[]),i=0;i<e.controlPointIndexArray.length;++i)n[i]=e.controlPointIndexArray[i]+t;this.controlPointIndexArray=this.controlPointIndexArray.concat(n)},_||{}),_=(_.math=_.math||{},_.math.Point2D=function(e,t){this.getX=function(){return e},this.getY=function(){return t}},_.math.Point2D.prototype.equals=function(e){return null!==e&&this.getX()===e.getX()&&this.getY()===e.getY()},_.math.Point2D.prototype.toString=function(){return"("+this.getX()+", "+this.getY()+")"},_.math.Point2D.prototype.getDistance=function(e){return Math.sqrt((this.getX()-e.getX())*(this.getX()-e.getX())+(this.getY()-e.getY())*(this.getY()-e.getY()))},_.math.Point2D.prototype.getRound=function(){return new _.math.Point2D(Math.round(this.getX()),Math.round(this.getY()))},_.math.Point3D=function(e,t,n){this.getX=function(){return e},this.getY=function(){return t},this.getZ=function(){return n}},_.math.Point3D.prototype.equals=function(e){return null!==e&&this.getX()===e.getX()&&this.getY()===e.getY()&&this.getZ()===e.getZ()},_.math.Point3D.prototype.isSimilar=function(e,t){return null!==e&&_.math.isSimilar(this.getX(),e.getX(),t)&&_.math.isSimilar(this.getY(),e.getY(),t)&&_.math.isSimilar(this.getZ(),e.getZ(),t)},_.math.Point3D.prototype.toString=function(){return"("+this.getX()+", "+this.getY()+", "+this.getZ()+")"},_.math.Point3D.prototype.getDistance=function(e){return Math.sqrt((this.getX()-e.getX())*(this.getX()-e.getX())+(this.getY()-e.getY())*(this.getY()-e.getY())+(this.getZ()-e.getZ())*(this.getZ()-e.getZ()))},_.math.Point3D.prototype.minus=function(e){return new _.math.Vector3D(this.getX()-e.getX(),this.getY()-e.getY(),this.getZ()-e.getZ())},_.math.getEqualPoint3DFunction=function(t){return function(e){return e.equals(t)}},_.math.getSimilarPoint3DFunction=function(t,n){return function(e){return e.isSimilar(t,n)}},_.math.Point=function(t){if(!t||void 0===t)throw new Error("Cannot create point with no values.");if(0===t.length)throw new Error("Cannot create point with empty values.");if(!t.every(function(e){return!isNaN(e)}))throw new Error("Cannot create point with non number values.");this.get=function(e){return t[e]},this.length=function(){return t.length},this.toString=function(){return"("+t.toString()+")"},this.getValues=function(){return t.slice()}},_.math.Point.prototype.canCompare=function(e){return!!e&&this.length()===e.length()},_.math.Point.prototype.equals=function(e){if(!this.canCompare(e))return!1;for(var t=0,n=this.length();t<n;++t)if(this.get(t)!==e.get(t))return!1;return!0},_.math.Point.prototype.compare=function(e){if(!this.canCompare(e))return null;for(var t=[],n=0,i=this.length();n<i;++n)this.get(n)!==e.get(n)&&t.push(n);return t},_.math.Point.prototype.get3D=function(){return new _.math.Point3D(this.get(0),this.get(1),this.get(2))},_.math.Point.prototype.add=function(e){if(!this.canCompare(e))return null;for(var t=[],n=this.getValues(),i=e.getValues(),r=0;r<n.length;++r)t.push(n[r]+i[r]);return new _.math.Point(t)},_.math.Point.prototype.mergeWith3D=function(e){var t=this.getValues();return t[0]=e.getX(),t[1]=e.getY(),t[2]=e.getZ(),new _.math.Point(t)},_||{}),_=(_.math=_.math||{},_.math.mulABC=function(e,t,n){return null!==t&&null!==n?e*t*n:null},_.math.Rectangle=function(e,t){var n;t.getX()<e.getX()&&(n=e.getX(),e=new _.math.Point2D(t.getX(),e.getY()),t=new _.math.Point2D(n,t.getY())),t.getY()<e.getY()&&(n=e.getY(),e=new _.math.Point2D(e.getX(),t.getY()),t=new _.math.Point2D(t.getX(),n)),this.getBegin=function(){return e},this.getEnd=function(){return t}},_.math.Rectangle.prototype.equals=function(e){return null!==e&&this.getBegin().equals(e.getBegin())&&this.getEnd().equals(e.getEnd())},_.math.Rectangle.prototype.getSurface=function(){var e=this.getBegin(),t=this.getEnd();return Math.abs(t.getX()-e.getX())*Math.abs(t.getY()-e.getY())},_.math.Rectangle.prototype.getWorldSurface=function(e,t){return _.math.mulABC(this.getSurface(),e,t)},_.math.Rectangle.prototype.getRealWidth=function(){return this.getEnd().getX()-this.getBegin().getX()},_.math.Rectangle.prototype.getRealHeight=function(){return this.getEnd().getY()-this.getBegin().getY()},_.math.Rectangle.prototype.getWidth=function(){return Math.abs(this.getRealWidth())},_.math.Rectangle.prototype.getHeight=function(){return Math.abs(this.getRealHeight())},_.math.Rectangle.prototype.getRound=function(){return{min:this.getBegin().getRound(),max:this.getEnd().getRound()}},_.math.Rectangle.prototype.quantify=function(e,t){var n={},i=e.get2DSpacing(),i=this.getWorldSurface(i[0],i[1]);return null!==i&&(n.surface={value:i/100,unit:_.i18n("unit.cm2")}),e.canQuantifyImage()&&(i=this.getRound(),e=e.getImageRegionValues(i.min,i.max),i=_.math.getStats(e,t),n.min={value:i.getMin(),unit:""},n.max={value:i.getMax(),unit:""},n.mean={value:i.getMean(),unit:""},n.stdDev={value:i.getStdDev(),unit:""},void 0!==i.getMedian&&(n.median={value:i.getMedian(),unit:""}),void 0!==i.getP25&&(n.p25={value:i.getP25(),unit:""}),void 0!==i.getP75&&(n.p75={value:i.getP75(),unit:""})),n},_||{}),_=(_.math=_.math||{},_.math.ROI=function(){var t=[];this.getPoint=function(e){return t[e]},this.getLength=function(){return t.length},this.addPoint=function(e){t.push(e)},this.addPoints=function(e){t=t.concat(e)}},_||{}),x=(_.math=_.math||{},2/(3*Math.PI)),_=(_.math.computeGreyscale=function(e,t,n){for(var i=[],r=0;r<n;r++){i[r]=[];for(var o=0;o<t;o++){var a=4*(r*t+o);i[r][o]=(e[a]+e[1+a]+e[2+a])/765}}return i.dx=function(e,t){return e+1===this[t].length&&e--,this[t][e+1]-this[t][e]},i.dy=function(e,t){return t+1===this.length&&t--,this[t][e]-this[t+1][e]},i.gradMagnitude=function(e,t){var n=this.dx(e,t),e=this.dy(e,t);return Math.sqrt(n*n+e*e)},i.laplace=function(e,t){var n=-16*this[t][e];return(n+=this[t-2][e])+(this[t-1][e-1]+2*this[t-1][e]+this[t-1][e+1])+(this[t][e-2]+2*this[t][e-1]+2*this[t][e+1]+this[t][e+2])+(this[t+1][e-1]+2*this[t+1][e]+this[t+1][e+1])+this[t+2][e]},i},_.math.computeGradient=function(e){for(var t=[],n=0,i=0,r=0,r=0;r<e.length-1;r++){for(t[r]=[],i=0;i<e[r].length-1;i++)t[r][i]=e.gradMagnitude(i,r),n=Math.max(t[r][i],n);t[r][e[r].length-1]=t[r][e.length-2]}t[e.length-1]=[];for(var o=0;o<t[0].length;o++)t[e.length-1][o]=t[e.length-2][o];for(r=0;r<t.length;r++)for(i=0;i<t[r].length;i++)t[r][i]=1-t[r][i]/n;return t},_.math.computeLaplace=function(e){var t=[];t[0]=[],t[1]=[];for(var n=1;n<e.length;n++)t[0][n]=1,t[1][n]=1;for(var i=2;i<e.length-2;i++){t[i]=[],t[i][0]=1,t[i][1]=1;for(var r=2;r<e[i].length-2;r++)t[i][r]=.33<e.laplace(r,i)?0:1;t[i][e[i].length-2]=1,t[i][e[i].length-1]=1}t[e.length-2]=[],t[e.length-1]=[];for(var o=1;o<e.length;o++)t[e.length-2][o]=1,t[e.length-1][o]=1;return t},_.math.computeGradX=function(e){for(var t=[],n=0;n<e.length;n++){t[n]=[];for(var i=0;i<e[n].length-1;i++)t[n][i]=e.dx(i,n);t[n][e[n].length-1]=t[n][e[n].length-2]}return t},_.math.computeGradY=function(e){for(var t=[],n=0;n<e.length-1;n++){t[n]=[];for(var i=0;i<e[n].length;i++)t[n][i]=e.dy(i,n)}t[e.length-1]=[];for(var r=0;r<e[0].length;r++)t[e.length-1][r]=t[e.length-2][r];return t},_.math.gradUnitVector=function(e,t,n,i,r){e=e[i][n],t=t[i][n],i=Math.sqrt(e*e+t*t),i=Math.max(i,1e-100);r.x=e/i,r.y=t/i},_.math.gradDirection=function(e,t,n,i,r,o){var a={x:-1,y:-1},s={x:-1,y:-1},e=(_.math.gradUnitVector(e,t,n,i,a),_.math.gradUnitVector(e,t,r,o,s),a.y*(r-n)-a.x*(o-i)),t=s.y*(r-n)-s.x*(o-i);return e<0&&(e=-e,t=-t),n!==r&&i!==o&&(e*=Math.SQRT1_2,t*=Math.SQRT1_2),x*(Math.acos(e)+Math.acos(t))},_.math.computeSides=function(e,t,n,i){for(var r={inside:[],outside:[]},o={x:-1,y:-1},a=0;a<t.length;a++){r.inside[a]=[],r.outside[a]=[];for(var s=0;s<t[a].length;s++){_.math.gradUnitVector(t,n,s,a,o);var u=Math.round(s+e*o.y),l=Math.round(a-e*o.x),c=Math.round(s-e*o.y),d=Math.round(a+e*o.x),u=Math.max(Math.min(u,t[a].length-1),0),c=Math.max(Math.min(c,t[a].length-1),0),l=Math.max(Math.min(l,t.length-1),0),d=Math.max(Math.min(d,t.length-1),0);r.inside[a][s]=i[l][u],r.outside[a][s]=i[d][c]}}return r},_.math.gaussianBlur=function(e,t){t[0]=.4*e[0]+.5*e[1]+.1*e[1],t[1]=.25*e[0]+.4*e[1]+.25*e[2]+.1*e[3];for(var n=2;n<e.length-2;n++)t[n]=.05*e[n-2]+.25*e[n-1]+.4*e[n]+.25*e[n+1]+.05*e[n+2];var i=e.length;t[i-2]=.25*e[i-1]+.4*e[i-2]+.25*e[i-3]+.1*e[i-4],t[i-1]=.4*e[i-1]+.5*e[i-2]+.1*e[i-3]},_.math.Scissors=function(){this.width=-1,this.height=-1,this.curPoint=null,this.searchGranBits=8,this.searchGran=1<<this.earchGranBits,this.pointsPerPost=500,this.greyscale=null,this.laplace=null,this.gradient=null,this.gradX=null,this.gradY=null,this.parents=null,this.working=!1,this.trained=!1,this.trainingPoints=null,this.edgeWidth=2,this.trainingLength=32,this.edgeGran=256,this.edgeTraining=null,this.gradPointsNeeded=32,this.gradGran=1024,this.gradTraining=null,this.insideGran=256,this.insideTraining=null,this.outsideGran=256,this.outsideTraining=null},_.math.Scissors.prototype.getTrainingIdx=function(e,t){return Math.round((e-1)*t)},_.math.Scissors.prototype.getTrainedEdge=function(e){return this.edgeTraining[this.getTrainingIdx(this.edgeGran,e)]},_.math.Scissors.prototype.getTrainedGrad=function(e){return this.gradTraining[this.getTrainingIdx(this.gradGran,e)]},_.math.Scissors.prototype.getTrainedInside=function(e){return this.insideTraining[this.getTrainingIdx(this.insideGran,e)]},_.math.Scissors.prototype.getTrainedOutside=function(e){return this.outsideTraining[this.getTrainingIdx(this.outsideGran,e)]},_.math.Scissors.prototype.setWorking=function(e){this.working=e},_.math.Scissors.prototype.setDimensions=function(e,t){this.width=e,this.height=t},_.math.Scissors.prototype.setData=function(e){if(-1===this.width||-1===this.height)throw new Error("Dimensions have not been set.");this.greyscale=_.math.computeGreyscale(e,this.width,this.height),this.laplace=_.math.computeLaplace(this.greyscale),this.gradient=_.math.computeGradient(this.greyscale),this.gradX=_.math.computeGradX(this.greyscale),this.gradY=_.math.computeGradY(this.greyscale);e=_.math.computeSides(this.edgeWidth,this.gradX,this.gradY,this.greyscale);this.inside=e.inside,this.outside=e.outside,this.edgeTraining=[],this.gradTraining=[],this.insideTraining=[],this.outsideTraining=[]},_.math.Scissors.prototype.findTrainingPoints=function(e){var t=[];if(null!==this.parents)for(var n=0;n<this.trainingLength&&e;n++)t.push(e),e=this.parents[e.y][e.x];return t},_.math.Scissors.prototype.resetTraining=function(){this.trained=!1},_.math.Scissors.prototype.doTraining=function(e){this.trainingPoints=this.findTrainingPoints(e),this.trainingPoints.length<8||(this.calculateTraining(e=[],this.edgeGran,this.greyscale,this.edgeTraining),this.calculateTraining(e,this.gradGran,this.gradient,this.gradTraining),this.calculateTraining(e,this.insideGran,this.inside,this.insideTraining),this.calculateTraining(e,this.outsideGran,this.outside,this.outsideTraining),this.trainingPoints.length<this.gradPointsNeeded&&this.addInStaticGrad(this.trainingPoints.length,this.gradPointsNeeded),this.trained=!0)},_.math.Scissors.prototype.calculateTraining=function(e,t,n,i){var r=0;for(e.length=t,r=0;r<t;r++)e[r]=0;for(var o=1,r=0;r<this.trainingPoints.length;r++){var a=this.trainingPoints[r],a=this.getTrainingIdx(t,n[a.y][a.x]);e[a]+=1,o=Math.max(o,e[a])}for(r=0;r<t;r++)e[r]=1-e[r]/o;_.math.gaussianBlur(e,i)},_.math.Scissors.prototype.addInStaticGrad=function(e,t){for(var n=0;n<this.gradGran;n++)this.gradTraining[n]=Math.min(this.gradTraining[n],1-n*(t-e)/(t*this.gradGran))},_.math.Scissors.prototype.gradDirection=function(e,t,n,i){return _.math.gradDirection(this.gradX,this.gradY,e,t,n,i)},_.math.Scissors.prototype.dist=function(e,t,n,i){var r=this.gradient[i][n],o=(e!==n&&t!==i||(r*=Math.SQRT1_2),this.laplace[i][n]),n=this.gradDirection(e,t,n,i);return this.trained?.3*this.getTrainedGrad(r)+.3*o+.1*(n+this.getTrainedEdge(this.greyscale[t][e])+this.getTrainedInside(this.inside[t][e])+this.getTrainedOutside(this.outside[t][e])):.43*r+.43*o+.11*n},_.math.Scissors.prototype.adj=function(e){for(var t=[],n=Math.max(e.x-1,0),i=Math.max(e.y-1,0),r=Math.min(e.x+1,this.greyscale[0].length-1),o=Math.min(e.y+1,this.greyscale.length-1),a=0,s=i;s<=o;s++)for(var u=n;u<=r;u++)u===e.x&&s===e.y||(t[a++]={x:u,y:s});return t},_.math.Scissors.prototype.setPoint=function(e){this.setWorking(!0),this.curPoint=e;var t=0,n=0;for(this.visited=[],n=0;n<this.height;n++)for(this.visited[n]=[],t=0;t<this.width;t++)this.visited[n][t]=!1;for(this.parents=[],n=0;n<this.height;n++)this.parents[n]=[];for(this.cost=[],n=0;n<this.height;n++)for(this.cost[n]=[],t=0;t<this.width;t++)this.cost[n][t]=Number.MAX_VALUE;this.pq=new _.math.BucketQueue(this.searchGranBits,function(e){return Math.round(this.searchGran*this.costArr[e.y][e.x])}),this.pq.searchGran=this.searchGran,this.pq.costArr=this.cost,this.pq.push(e),this.cost[e.y][e.x]=0},_.math.Scissors.prototype.doWork=function(){if(this.working){this.timeout=null;for(var e=0,t=[];!this.pq.isEmpty()&&e<this.pointsPerPost;){for(var n=this.pq.pop(),i=(t.push(n),t.push(this.parents[n.y][n.x]),this.visited[n.y][n.x]=!0,this.adj(n)),r=0;r<i.length;r++){var o=i[r],a=this.cost[n.y][n.x]+this.dist(n.x,n.y,o.x,o.y);a<this.cost[o.y][o.x]&&(this.cost[o.y][o.x]!==Number.MAX_VALUE&&this.pq.remove(o),this.cost[o.y][o.x]=a,this.parents[o.y][o.x]=n,this.pq.push(o))}e++}return t}},_||{}),_=(_.math=_.math||{},_.math.SimpleStats=function(e,t,n,i){this.getMin=function(){return e},this.getMax=function(){return t},this.getMean=function(){return n},this.getStdDev=function(){return i}},_.math.SimpleStats.prototype.equals=function(e){return null!==e&&this.getMin()===e.getMin()&&this.getMax()===e.getMax()&&this.getMean()===e.getMean()&&this.getStdDev()===e.getStdDev()},_.math.SimpleStats.prototype.asObject=function(){return{min:this.getMin(),max:this.getMax(),mean:this.getMean(),stdDev:this.getStdDev()}},_.math.FullStats=function(e,t,n,i,r,o,a){_.math.SimpleStats.call(this,e,t,n,i),this.getMedian=function(){return r},this.getP25=function(){return o},this.getP75=function(){return a}},_.math.FullStats.prototype=Object.create(_.math.SimpleStats.prototype),Object.defineProperty(_.math.FullStats.prototype,"constructor",{value:_.math.FullStats,enumerable:!1,writable:!0}),_.math.getStats=function(e,t){return _.math.includesFullStatsFlags(t)?_.math.getFullStats(e):_.math.getSimpleStats(e)},_.math.includesFullStatsFlags=function(e){return null!=e&&e.includes("median","p25","p75")},_.math.getSimpleStats=function(e){for(var t,n=e[0],i=n,r=0,o=0,a=e.length,s=0;s<a;++s)(t=e[s])<n?n=t:i<t&&(i=t),r+=t,o+=t*t;var u=r/a,l=Math.sqrt(o/a-u*u);return new _.math.SimpleStats(n,i,u,l)},_.math.getFullStats=function(e){var t=_.math.getSimpleStats(e),n=(e.sort(function(e,t){return e-t}),_.math.getPercentile(e,.5)),i=_.math.getPercentile(e,.25),e=_.math.getPercentile(e,.75);return new _.math.FullStats(t.getMin(),t.getMax(),t.getMean(),t.getStdDev(),n,i,e)},_.math.getPercentile=function(e,t){if(0===e.length)throw new Error("Empty array provided for percentile calculation.");if(t<0||1<t)throw new Error("Invalid ratio provided for percentile calculation: "+t);if(0===t)return e[0];if(1===t)return e[e.length-1];var t=(e.length-1)*t,n=Math.floor(t),i=e[n];return i+(e[n+1]-i)*(t-n)},_.math.guid=function(){return Math.random().toString(36).substring(2,15)},_||{}),_=(_.math=_.math||{},_.math.Vector3D=function(e,t,n){this.getX=function(){return e},this.getY=function(){return t},this.getZ=function(){return n}},_.math.Vector3D.prototype.equals=function(e){return null!==e&&this.getX()===e.getX()&&this.getY()===e.getY()&&this.getZ()===e.getZ()},_.math.Vector3D.prototype.toString=function(){return"("+this.getX()+", "+this.getY()+", "+this.getZ()+")"},_.math.Vector3D.prototype.norm=function(){return Math.sqrt(this.getX()*this.getX()+this.getY()*this.getY()+this.getZ()*this.getZ())},_.math.Vector3D.prototype.crossProduct=function(e){return new _.math.Vector3D(this.getY()*e.getZ()-e.getY()*this.getZ(),this.getZ()*e.getX()-e.getZ()*this.getX(),this.getX()*e.getY()-e.getX()*this.getY())},_.math.Vector3D.prototype.dotProduct=function(e){return this.getX()*e.getX()+this.getY()*e.getY()+this.getZ()*e.getZ()},_||{}),L=(_.tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_=(_.tool.draw.defaultArrowLabelText="",_.tool.draw.ArrowFactory=function(){this.getGroupName=function(){return"line-group"},this.getNPoints=function(){return 2},this.getTimeout=function(){return 0}},_.tool.draw.ArrowFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.ArrowFactory.prototype.create=function(e,t,n){var i=new _.math.Line(e[0],e[1]),r=new L.Line({points:[i.getBegin().getX(),i.getBegin().getY(),i.getEnd().getX(),i.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),o=_.math.getPerpendicularLine(i,e[0],t.scale(10)),a=_.math.getPerpendicularLine(i,e[1],t.scale(10)),e=(r.hitFunc(function(e){e.beginPath(),e.moveTo(o.getBegin().getX(),o.getBegin().getY()),e.lineTo(o.getEnd().getX(),o.getEnd().getY()),e.lineTo(a.getEnd().getX(),a.getEnd().getY()),e.lineTo(a.getBegin().getX(),a.getBegin().getY()),e.closePath(),e.fillStrokeShape(this)}),new _.math.Point2D(i.getBegin().getX(),i.getBegin().getY()-10)),e=new _.math.Line(i.getBegin(),e),e=_.math.getAngle(i,e),s=e*Math.PI/180,u=5*t.getScaledStrokeWidth(),s=new L.RegularPolygon({x:i.getBegin().getX()+u*Math.sin(s),y:i.getBegin().getY()+u*Math.cos(s),sides:3,radius:u,rotation:-e,fill:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape-triangle"}),u=new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"}),e="",e=void 0!==_.tool.draw.arrowLabelText?_.tool.draw.arrowLabelText:_.tool.draw.defaultArrowLabelText,l=(u.setText(e),u.meta={textExpr:e,quantification:{}},i.getBegin().getX()>i.getEnd().getX()?0:-1),c=i.getBegin().getY()>i.getEnd().getY()?-1:0,l=new L.Label({x:i.getEnd().getX()+l*u.width(),y:i.getEnd().getY()+c*t.applyZoomScale(15).y,scale:t.applyZoomScale(1),visible:0!==e.length,name:"label"}),i=(l.add(u),l.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),new L.Group);return i.name(this.getGroupName()),i.add(l),i.add(s),i.add(r),i.visible(!0),i},_.tool.draw.ArrowFactory.prototype.getAnchors=function(e,t){var n=e.points(),i=[];return i.push(_.tool.draw.getDefaultAnchor(n[0]+e.x(),n[1]+e.y(),"begin",t)),i.push(_.tool.draw.getDefaultAnchor(n[2]+e.x(),n[3]+e.y(),"end",t)),i},_.tool.draw.ArrowFactory.prototype.update=function(e,t,n){var i=e.getParent(),r=i.getChildren(function(e){return"shape"===e.name()})[0],o=i.getChildren(function(e){return"shape-triangle"===e.name()})[0],a=i.getChildren(function(e){return"label"===e.name()})[0],s=i.getChildren(function(e){return"begin"===e.id()})[0],u=i.getChildren(function(e){return"end"===e.id()})[0];switch(e.id()){case"begin":s.x(e.x()),s.y(e.y());break;case"end":u.x(e.x()),u.y(e.y())}var i=s.x()-r.x(),l=s.y()-r.y(),c=u.x()-r.x(),d=u.y()-r.y(),g=(r.points([i,l,c,d]),new _.math.Point2D(s.x(),s.y())),x=new _.math.Point2D(u.x(),u.y()),g=new _.math.Line(g,x),x=new _.math.Point2D(i,l),i=new _.math.Point2D(c,d),S=_.math.getPerpendicularLine(g,x,10),m=_.math.getPerpendicularLine(g,i,10),l=(r.hitFunc(function(e){e.beginPath(),e.moveTo(S.getBegin().getX(),S.getBegin().getY()),e.lineTo(S.getEnd().getX(),S.getEnd().getY()),e.lineTo(m.getEnd().getX(),m.getEnd().getY()),e.lineTo(m.getBegin().getX(),m.getBegin().getY()),e.closePath(),e.fillStrokeShape(this)}),new _.math.Point2D(g.getBegin().getX(),g.getBegin().getY()-10)),c=new _.math.Line(g.getBegin(),l),d=_.math.getAngle(g,c),x=d*Math.PI/180,i=(o.x(g.getBegin().getX()+o.radius()*Math.sin(x)),o.y(g.getBegin().getY()+o.radius()*Math.cos(x)),o.rotation(-d),a.getText()),r=(i.setText(i.meta.textExpr),g.getBegin().getX()>g.getEnd().getX()?0:-1),l=g.getBegin().getY()>g.getEnd().getY()?-1:0,c={x:g.getEnd().getX()+r*i.width(),y:g.getEnd().getY()+l*t.applyZoomScale(15).y};a.position(c)},_||{}),L=(_.tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_=(_.tool.draw.defaultCircleLabelText="{surface}",_.tool.draw.CircleFactory=function(){this.getGroupName=function(){return"circle-group"},this.getNPoints=function(){return 2},this.getTimeout=function(){return 0}},_.tool.draw.CircleFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.CircleFactory.prototype.create=function(e,t,n){var i,r=Math.abs(e[0].getX()-e[1].getX()),o=Math.abs(e[0].getY()-e[1].getY()),r=Math.round(Math.sqrt(r*r+o*o)),o=new _.math.Circle(e[0],r),e=new L.Circle({x:o.getCenter().getX(),y:o.getCenter().getY(),radius:o.getRadius(),stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),r=new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"}),a="",a=void 0!==_.tool.draw.circleLabelText?_.tool.draw.circleLabelText:_.tool.draw.defaultCircleLabelText,n=o.quantify(n,_.utils.getFlags(a)),n=(r.setText(_.utils.replaceFlags(a,n)),r.meta={textExpr:a,quantification:n},new L.Label({x:o.getCenter().getX(),y:o.getCenter().getY(),scale:t.applyZoomScale(1),visible:0!==a.length,name:"label"})),a=(n.add(r),n.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),_.tool.draw.debug&&(i=_.tool.draw.getShadowCircle(o)),new L.Group);return a.name(this.getGroupName()),i&&a.add(i),a.add(n),a.add(e),a.visible(!0),a},_.tool.draw.CircleFactory.prototype.getAnchors=function(e,t){var n=e.x(),i=e.y(),e=e.radius(),r=[];return r.push(_.tool.draw.getDefaultAnchor(n-e,i,"left",t)),r.push(_.tool.draw.getDefaultAnchor(n+e,i,"right",t)),r.push(_.tool.draw.getDefaultAnchor(n,i-e,"bottom",t)),r.push(_.tool.draw.getDefaultAnchor(n,i+e,"top",t)),r},_.tool.draw.CircleFactory.prototype.update=function(e,t,n){var i,r,o=e.getParent(),a=o.getChildren(function(e){return"shape"===e.name()})[0],s=o.getChildren(function(e){return"label"===e.name()})[0],u=o.getChildren(function(e){return"left"===e.id()})[0],l=o.getChildren(function(e){return"right"===e.id()})[0],c=o.getChildren(function(e){return"bottom"===e.id()})[0],d=o.getChildren(function(e){return"top"===e.id()})[0],g=(_.tool.draw.debug&&(i=o.getChildren(function(e){return"shadow"===e.name()})[0]),{x:a.x(),y:a.y()});switch(e.id()){case"left":r=g.x-e.x(),u.y(l.y()),l.x(g.x+r),c.y(g.y-r),d.y(g.y+r);break;case"right":r=e.x()-g.x,l.y(u.y()),u.x(g.x-r),c.y(g.y-r),d.y(g.y+r);break;case"bottom":r=g.y-e.y(),c.x(d.x()),u.x(g.x-r),l.x(g.x+r),d.y(g.y+r);break;case"top":r=e.y()-g.y,d.x(c.x()),u.x(g.x-r),l.x(g.x+r),c.y(g.y-r);break;default:_.logger.error("Unhandled anchor id: "+e.id())}a.radius(Math.abs(r));a=new _.math.Point2D(o.x()+g.x,o.y()+g.y),a=new _.math.Circle(a,r);i&&(i.destroy(),o.add(_.tool.draw.getShadowCircle(a,o))),s.position({x:g.x,y:g.y}),_.tool.draw.updateCircleQuantification(o,n)},_.tool.draw.CircleFactory.prototype.updateQuantification=function(e,t){_.tool.draw.updateCircleQuantification(e,t)},_.tool.draw.updateCircleQuantification=function(e,t){var n=e.getChildren(function(e){return"shape"===e.name()})[0],i=e.getChildren(function(e){return"label"===e.name()})[0],e=new _.math.Point2D(e.x()+n.x(),e.y()+n.y()),e=new _.math.Circle(e,n.radius()),n=i.getText(),i=e.quantify(t,_.utils.getFlags(n.meta.textExpr));n.setText(_.utils.replaceFlags(n.meta.textExpr,i)),n.meta.quantification=i},_.tool.draw.getShadowCircle=function(e,t){for(var n=0,i=0,r=(void 0!==t&&(n=t.x(),i=t.y()),new L.Group),o=(r.name("shadow"),e.getRound()),a=0;a<o.length;++a){var s=o[a],u=s[0][0],l=s[0][1],s=s[1][0],l=new L.Rect({x:u-n,y:l-i,width:s-u,height:1,fill:"grey",strokeWidth:0,strokeScaleEnabled:!1,opacity:.3,name:"shadow-element"});r.add(l)}return r},_||{}),L=(_.tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_=(_.tool.draw.debug=!1,_.tool.Draw=function(d){var e,g,x=this,r=!1,o=this.shapeFactoryList=null,a=null,s=null,u=(this.shapeName=0,[]),l=null,t="pointer",n=new _.tool.ScrollWheel(d),S=new _.tool.ShapeEditor(d),m=(S.setDrawEventCallback(T),new L.Group),i=new L.Line({points:[-10,-10,10,10],stroke:"red"}),c=new L.Line({points:[10,-10,-10,10],stroke:"red"}),h=(m.width(20),m.height(20),m.add(i),m.add(c),this.style=d.getStyle(),{});function f(e,t){var n=t.getActiveDrawLayer().getKonvaLayer(),t=(s&&(s.destroy(),s=null),t.getActiveViewLayer().getViewController());(s=o.create(e,x.style,t)).getChildren(_.draw.isNodeNameShape)[0].listening(!1),n.listening(!1),n.add(s),n.draw()}function p(e,t){var n=t.getActiveDrawLayer().getKonvaLayer(),i=(s&&(s.destroy(),s=null),t.getActiveViewLayer().getViewController()),r=t.getActiveDrawLayer().getDrawController(),e=o.create(e,x.style,i);e.id(_.math.guid()),r.getCurrentPosGroup().add(e),n.listening(!0),(a=new _.tool.DrawGroupCommand(e,x.shapeName,n)).onExecute=T,a.onUndo=T,a.execute(),d.addToUndoStack(a),x.setShapeOn(e,t)}function y(e){D(!0,e)}function D(e,t){var n=t.getActiveDrawLayer().getDrawController().getCurrentPosGroup().getChildren();e?n.forEach(function(e){x.setShapeOn(e,t)}):n.forEach(function(e){(e=e).off("mouseover"),e.off("mouseout"),e.draggable(!1),e.off("dragstart.draw"),e.off("dragmove.draw"),e.off("dragend.draw"),e.off("dblclick")});e=t.getActiveDrawLayer().getKonvaLayer();0!==n.length&&e.listening(!0),e.draw()}function v(e,t){t=t.getActiveDrawLayer().getKonvaStage();return{x:t.offset().x+e.x/t.scale().x,y:t.offset().y+e.y/t.scale().y}}function C(){var t;void 0!==g&&(document.body.style.cursor=g),void 0!==e&&(e.opacity(1),t=x.style.getLineColour(),e.getChildren(_.draw.canNodeChangeColour).forEach(function(e){e.stroke(t)}))}function T(e){if(void 0!==h[e.type])for(var t=0;t<h[e.type].length;++t)h[e.type][t](e)}this.mousedown=function(e){var t,n,i;r||(t=_.gui.getLayerDetailsFromEvent(e),n=(i=(t=d.getLayerGroupByDivId(t.groupDivId)).getActiveDrawLayer().getKonvaStage()).getIntersection({x:e._x,y:e._y}),x.style.setZoomScale(i.scale()),n?(i=n.getParent().find(".shape")[0])&&i!==S.getShape()&&(S.disable(),S.setShape(i),n=t.getActiveViewLayer().getViewController(),S.setViewController(n),S.enable()):(S.disable(),S.setShape(null),S.setViewController(null),r=!0,o=new x.shapeFactoryList[x.shapeName],u=[],i=t.getActiveViewLayer().displayToPlanePos(e._x,e._y),l=new _.math.Point2D(i.x,i.y),u.push(l)))},this.mousemove=function(e){var t;r&&(t=_.gui.getLayerDetailsFromEvent(e),e=(t=d.getLayerGroupByDivId(t.groupDivId)).getActiveViewLayer().displayToPlanePos(e._x,e._y),(0<Math.abs(e.x-l.getX())||0<Math.abs(e.y-l.getY()))&&(1!==u.length&&void 0!==u[u.length-1].tmp&&u.pop(),(l=new _.math.Point2D(e.x,e.y)).tmp=!0,u.push(l),f(u,t)))},this.mouseup=function(e){r&&(0===u.length?_.logger.warn("Draw mouseup but no points..."):u.length===o.getNPoints()?(e=_.gui.getLayerDetailsFromEvent(e),e=d.getLayerGroupByDivId(e.groupDivId),p(u,e),r=!1):void 0!==u[u.length-1].tmp&&delete u[u.length-1].tmp)},this.dblclick=function(e){void 0===o.getNPoints()&&r&&(0===u.length?_.logger.warn("Draw dblclick but no points..."):(e=_.gui.getLayerDetailsFromEvent(e),e=d.getLayerGroupByDivId(e.groupDivId),p(u,e),r=!1))},this.mouseout=function(e){x.mouseup(e)},this.touchstart=function(e){x.mousedown(e)},this.touchmove=function(e){var t;r&&(t=_.gui.getLayerDetailsFromEvent(e),e=(t=d.getLayerGroupByDivId(t.groupDivId)).getActiveViewLayer().displayToPlanePos(e._x,e._y),(0<Math.abs(e.x-l.getX())||0<Math.abs(e.y-l.getY()))&&(1!==u.length&&u.pop(),l=new _.math.Point2D(e.x,e.y),u.push(l),u.length<o.getNPoints()&&(clearTimeout(this.timer),this.timer=setTimeout(function(){u.push(l)},o.getTimeout())),f(u,t)))},this.touchend=function(e){x.dblclick(e)},this.wheel=function(e){n.wheel(e)},this.keydown=function(e){var t,n,i;r||(e.context="dwv.tool.Draw",d.onKeydown(e)),"Delete"!==e.key&&"Backspace"!==e.key||!S.isActive()||(t=(i=S.getShape().getParent()).getLayer(),n=_.tool.GetShapeDisplayName(i.getChildren(_.draw.isNodeNameShape)[0]),(i=new _.tool.DeleteGroupCommand(i,n,t)).onExecute=T,i.onUndo=T,i.execute(),d.addToUndoStack(i)),"Escape"===e.key&&null!==s&&(t=s.getLayer(),s.destroy(),s=null,r=!1,u=[],t.draw())},this.activate=function(e){S.disable(),S.setShape(null),S.setViewController(null);var t=d.getActiveLayerGroup();D(e,t),e?(g=document.body.style.cursor,d.addEventListener("positionchange",function(){y(t)}),this.setFeatures({lineColour:this.style.getLineColour()})):(C(),g=void 0,d.removeEventListener("positionchange",function(){y(t)}))},this.setShapeOn=function(a,s){a.on("mouseover",function(){e=a,document.body.style.cursor=t,a.opacity(.75)}),a.on("mouseout",function(){C(),e=void 0});var u=s.getActiveDrawLayer().getKonvaLayer(),o=(a.draggable(!0),{x:a.x(),y:a.y()}),l=_.tool.GetShapeDisplayName(a.getChildren(_.draw.isNodeNameShape)[0]),c=null;a.on("dragstart.draw",function(){c=a.getChildren(_.draw.isNodeNameShape)[0].stroke();var e=s.getActiveDrawLayer().getKonvaStage(),t=e.scale(),n={x:1/t.x,y:1/t.y};m.x(e.offset().x+e.width()/(2*t.x)),m.y(e.offset().y+e.height()/(15*t.y)),m.scale(n),u.add(m),S.setAnchorsActive(!1),u.draw()}),a.on("dragmove.draw",function(e){for(var t,n=s.getActiveDrawLayer(),i=(_.tool.validateGroupPosition(n.getBaseSize(),this),Object.keys(x.shapeFactoryList)),r=0;r<i.length&&!(t=new x.shapeFactoryList[i[r]]).isFactoryGroup(a);++r);if(void 0===t)throw new Error("Cannot find factory to update quantification.");void 0!==t.updateQuantification&&(n=s.getActiveViewLayer().getViewController(),t.updateQuantification(this,n));var n=v(_.gui.getEventOffset(e.evt)[0],s),e=m.width()*m.scaleX()/2,o=m.height()*m.scaleY()/2;Math.abs(n.x-m.x())<e&&Math.abs(n.y-m.y())<o?(m.getChildren().forEach(function(e){e.stroke("orange")}),a.getChildren(_.draw.canNodeChangeColour).forEach(function(e){e.stroke("red")})):(m.getChildren().forEach(function(e){e.stroke("red")}),a.getChildren(_.draw.canNodeChangeColour).forEach(function(e){void 0!==e.stroke&&e.stroke(c)})),u.draw()}),a.on("dragend.draw",function(e){var t,n,i,r;m.remove(),void 0!==e&&void 0!==e.evt&&(t=this.x(),n=this.y(),e=v(_.gui.getEventOffset(e.evt)[0],s),i=m.width()*m.scaleX()/2,r=m.height()*m.scaleY()/2,Math.abs(e.x-m.x())<i&&Math.abs(e.y-m.y())<r?(this.x(o.x),this.y(o.y),S.disable(),S.setShape(null),S.setViewController(null),a.getChildren(_.draw.canNodeChangeColour).forEach(function(e){e.stroke(c)}),document.body.style.cursor=g,(i=new _.tool.DeleteGroupCommand(this,l,u)).onExecute=T,i.onUndo=T,i.execute(),d.addToUndoStack(i)):(0===(e={x:t-o.x,y:n-o.y}).x&&0===e.y||((r=new _.tool.MoveGroupCommand(this,l,e,u)).onExecute=T,r.onUndo=T,d.addToUndoStack(r),T({type:"drawmove",id:this.id()})),S.setAnchorsActive(!0),S.resetAnchors()),u.draw(),o={x:this.x(),y:this.y()})}),a.on("dblclick",function(){var t=this.findOne("Label");if(void 0===t)throw new Error("Could not find the shape label.");function e(e){i.meta=e,i.setText(_.utils.replaceFlags(i.meta.textExpr,i.meta.quantification)),t.setVisible(0!==i.meta.textExpr.length),T({type:"drawchange",id:r}),u.draw()}var n,i=t.getText(),r=this.id();void 0!==_.openRoiDialog?_.openRoiDialog(i.meta,e):null!==(n=_.prompt("Label",i.meta.textExpr))&&(i.meta.textExpr=n,e(i.meta))})},this.setOptions=function(e){this.shapeFactoryList=e,S.setFactoryList(e)},this.getOptionsType=function(){return"factory"},this.setFeatures=function(e){if(void 0!==e.shapeColour&&this.style.setLineColour(e.shapeColour),void 0!==e.shapeName){if(!this.hasShape(e.shapeName))throw new Error("Unknown shape: '"+e.shapeName+"'");this.shapeName=e.shapeName}void 0!==e.mouseOverCursor&&(t=e.mouseOverCursor)},this.init=function(){},this.getEventNames=function(){return["drawcreate","drawchange","drawmove","drawdelete","drawlabelchange"]},this.addEventListener=function(e,t){void 0===h[e]&&(h[e]=[]),h[e].push(t)},this.removeEventListener=function(e,t){if(void 0!==h[e])for(var n=0;n<h[e].length;++n)h[e][n]===t&&h[e].splice(n,1)}},_.tool.Draw.prototype.hasShape=function(e){return this.shapeFactoryList[e]},_.tool.getAnchorMin=function(e){var t=e.find(".anchor");if(0!==t.length){for(var n=t[0].x(),i=t[0].y(),r=0;r<t.length;++r)n=Math.min(n,t[r].x()),i=Math.min(i,t[r].y());return{x:n,y:i}}},_.tool.boundNodePosition=function(e,t,n){var i=!1;return e.x()<t.x?(e.x(t.x),i=!0):e.x()>n.x&&(e.x(n.x),i=!0),e.y()<t.y?(e.y(t.y),i=!0):e.y()>n.y&&(e.y(n.y),i=!0),i},_.tool.validateGroupPosition=function(e,t){var n=t.getChildren(_.draw.isNodeNameShape)[0],i=_.tool.getAnchorMin(t);if(void 0===i)return null;var r={x:-i.x,y:-i.y},e={x:e.x-(i.x+Math.abs(n.width())),y:e.y-(i.y+Math.abs(n.height()))};return _.tool.boundNodePosition(t,r,e)},_.tool.validateAnchorPosition=function(e,t){var n=t.getParent(),i={x:-n.x(),y:-n.y()},e={x:e.x-n.x(),y:e.y-n.y()};return _.tool.boundNodePosition(t,i,e)},_||{}),L=(_.tool=_.tool||{},L||{}),_=(_.tool.GetShapeDisplayName=function(e){var t="shape";return e instanceof L.Line?t=4===e.points().length?"line":6===e.points().length?"protractor":"roi":e instanceof L.Rect?t="rectangle":e instanceof L.Ellipse&&(t="ellipse"),t},_.tool.DrawGroupCommand=function(e,t,n,i){var r=void 0!==i&&i,o=e.getParent();this.getName=function(){return"Draw-"+t},this.execute=function(){o.add(e),n.draw(),r||this.onExecute({type:"drawcreate",id:e.id()})},this.undo=function(){e.remove(),n.draw(),this.onUndo({type:"drawdelete",id:e.id()})}},_.tool.DrawGroupCommand.prototype.onExecute=function(e){},_.tool.DrawGroupCommand.prototype.onUndo=function(e){},_.tool.MoveGroupCommand=function(t,e,n,i){this.getName=function(){return"Move-"+e},this.execute=function(){t.move(n),i.draw(),this.onExecute({type:"drawmove",id:t.id()})},this.undo=function(){var e={x:-n.x,y:-n.y};t.move(e),i.draw(),this.onUndo({type:"drawmove",id:t.id()})}},_.tool.MoveGroupCommand.prototype.onExecute=function(e){},_.tool.MoveGroupCommand.prototype.onUndo=function(e){},_.tool.ChangeGroupCommand=function(e,t,n,i,r,o,a){this.getName=function(){return"Change-"+e},this.execute=function(){t(i,a,o),r.draw(),this.onExecute({type:"drawchange",id:i.getParent().id()})},this.undo=function(){t(n,a,o),r.draw(),this.onUndo({type:"drawchange",id:n.getParent().id()})}},_.tool.ChangeGroupCommand.prototype.onExecute=function(e){},_.tool.ChangeGroupCommand.prototype.onUndo=function(e){},_.tool.DeleteGroupCommand=function(e,t,n){var i=e.getParent();this.getName=function(){return"Delete-"+t},this.execute=function(){e.remove(),n.draw(),this.onExecute({type:"drawdelete",id:e.id()})},this.undo=function(){i.add(e),n.draw(),this.onUndo({type:"drawcreate",id:e.id()})}},_.tool.DeleteGroupCommand.prototype.onExecute=function(e){},_.tool.DeleteGroupCommand.prototype.onUndo=function(e){},_||{}),L=(_.tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_=(_.tool.draw.getDefaultAnchor=function(e,t,n,i){var r=i.applyZoomScale(3);return new L.Ellipse({x:e,y:t,stroke:"#999",fill:"rgba(100,100,100,0.7",strokeWidth:i.getStrokeWidth(),strokeScaleEnabled:!1,radius:{x:Math.abs(r.x),y:Math.abs(r.y)},name:"anchor",id:n,dragOnTop:!1,draggable:!0,visible:!1})},_.tool.ShapeEditor=function(o){var a=null,s=null,u=null,l=null,e=!1,c=null;function n(e){u&&u.getParent()&&u.getParent().find(".anchor").forEach(e)}function t(t){n(function(e){e.visible(t)})}function d(){n(function(e){e.remove()})}function g(){if(u&&u.getLayer())for(var e=u.getParent(),t=s.getAnchors(u,o.getStyle()),n=0;n<t.length;++n)i(t[n]),e.add(t[n])}function x(e){var t=e.getParent(),n=e.id(),i=e.x(),r=e.y(),e={getParent:function(){return t},id:function(){return n},x:function(){return i},y:function(){return r}};return e}function i(e){var i=null,r=_.tool.GetShapeDisplayName(u);e.on("dragstart.edit",function(e){i=x(this),e.cancelBubble=!0}),e.on("dragmove.edit",function(e){var t=_.gui.getLayerDetailsFromEvent(e.evt),t=o.getLayerGroupByDivId(t.groupDivId).getActiveDrawLayer();_.tool.validateAnchorPosition(t.getBaseSize(),this),s.update(this,o.getStyle(),l),this.getLayer()?this.getLayer().draw():_.logger.warn("No layer to draw the anchor!"),e.cancelBubble=!0}),e.on("dragend.edit",function(e){var t=x(this),n=new _.tool.ChangeGroupCommand(r,s.update,i,t,this.getLayer(),l,o.getStyle());n.onExecute=c,n.onUndo=c,n.execute(),o.addToUndoStack(n),i=t,e.cancelBubble=!0}),e.on("mousedown touchstart",function(){this.moveToTop()}),e.on("mouseover.edit",function(){this.stroke("#ddd"),this.getLayer()?this.getLayer().draw():_.logger.warn("No layer to draw the anchor!")}),e.on("mouseout.edit",function(){this.stroke("#999"),this.getLayer()?this.getLayer().draw():_.logger.warn("No layer to draw the anchor!")})}this.setFactoryList=function(e){a=e},this.setShape=function(e){if(u=e){d();var t=u.getParent(),n=Object.keys(a);s=null;for(var i=0;i<n.length;++i){var r=new a[n[i]];if(r.isFactoryGroup(t)){s=r;break}}if(null===s)throw new Error("Could not find a factory to update shape.");g()}},this.setViewController=function(e){l=e},this.getShape=function(){return u},this.isActive=function(){return e},this.setDrawEventCallback=function(e){c=e},this.enable=function(){e=!0,u&&(t(!0),u.getLayer()&&u.getLayer().draw())},this.disable=function(){e=!1,u&&(t(!1),u.getLayer()&&u.getLayer().draw())},this.resetAnchors=function(){d(),g(),t(!0)},this.setAnchorsActive=function(e){n(e?function(e){i(e)}:function(e){(e=e).off("dragstart.edit"),e.off("dragmove.edit"),e.off("dragend.edit"),e.off("mousedown touchstart"),e.off("mouseover.edit"),e.off("mouseout.edit")})}},_||{}),L=(_.tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_=(_.tool.draw.defaultEllipseLabelText="{surface}",_.tool.draw.EllipseFactory=function(){this.getGroupName=function(){return"ellipse-group"},this.getNPoints=function(){return 2},this.getTimeout=function(){return 0}},_.tool.draw.EllipseFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.EllipseFactory.prototype.create=function(e,t,n){var i,r=Math.abs(e[0].getX()-e[1].getX()),o=Math.abs(e[0].getY()-e[1].getY()),e=new _.math.Ellipse(e[0],r,o),r=new L.Ellipse({x:e.getCenter().getX(),y:e.getCenter().getY(),radius:{x:e.getA(),y:e.getB()},stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),o=new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"}),a="",a=void 0!==_.tool.draw.ellipseLabelText?_.tool.draw.ellipseLabelText:_.tool.draw.defaultEllipseLabelText,n=e.quantify(n,_.utils.getFlags(a)),n=(o.setText(_.utils.replaceFlags(a,n)),o.meta={textExpr:a,quantification:n},new L.Label({x:e.getCenter().getX(),y:e.getCenter().getY(),scale:t.applyZoomScale(1),visible:0!==a.length,name:"label"})),a=(n.add(o),n.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),_.tool.draw.debug&&(i=_.tool.draw.getShadowEllipse(e)),new L.Group);return a.name(this.getGroupName()),i&&a.add(i),a.add(n),a.add(r),a.visible(!0),a},_.tool.draw.EllipseFactory.prototype.getAnchors=function(e,t){var n=e.x(),i=e.y(),e=e.radius(),r=[];return r.push(_.tool.draw.getDefaultAnchor(n-e.x,i-e.y,"topLeft",t)),r.push(_.tool.draw.getDefaultAnchor(n+e.x,i-e.y,"topRight",t)),r.push(_.tool.draw.getDefaultAnchor(n+e.x,i+e.y,"bottomRight",t)),r.push(_.tool.draw.getDefaultAnchor(n-e.x,i+e.y,"bottomLeft",t)),r},_.tool.draw.EllipseFactory.prototype.update=function(e,t,n){var i,r=e.getParent(),o=r.getChildren(function(e){return"shape"===e.name()})[0],a=r.getChildren(function(e){return"label"===e.name()})[0],s=r.getChildren(function(e){return"topLeft"===e.id()})[0],u=r.getChildren(function(e){return"topRight"===e.id()})[0],l=r.getChildren(function(e){return"bottomRight"===e.id()})[0],c=r.getChildren(function(e){return"bottomLeft"===e.id()})[0];switch(_.tool.draw.debug&&(i=r.getChildren(function(e){return"shadow"===e.name()})[0]),e.id()){case"topLeft":s.x(e.x()),s.y(e.y()),u.y(e.y()),c.x(e.x());break;case"topRight":u.x(e.x()),u.y(e.y()),s.y(e.y()),l.x(e.x());break;case"bottomRight":l.x(e.x()),l.y(e.y()),c.y(e.y()),u.x(e.x());break;case"bottomLeft":c.x(e.x()),c.y(e.y()),l.y(e.y()),s.x(e.x());break;default:_.logger.error("Unhandled anchor id: "+e.id())}var d=(u.x()-s.x())/2,g=(l.y()-u.y())/2,x={x:s.x()+d,y:u.y()+g},d=(o.position(x),{x:Math.abs(d),y:Math.abs(g)}),g=(o.radius(d),new _.math.Point2D(r.x()+x.x,r.y()+x.y)),o=new _.math.Ellipse(g,d.x,d.y);i&&(i.destroy(),r.add(_.tool.draw.getShadowEllipse(o,r))),a.position({x:x.x,y:x.y}),_.tool.draw.updateEllipseQuantification(r,n)},_.tool.draw.EllipseFactory.prototype.updateQuantification=function(e,t){_.tool.draw.updateEllipseQuantification(e,t)},_.tool.draw.updateEllipseQuantification=function(e,t){var n=e.getChildren(function(e){return"shape"===e.name()})[0],i=e.getChildren(function(e){return"label"===e.name()})[0],e=new _.math.Point2D(e.x()+n.x(),e.y()+n.y()),e=new _.math.Ellipse(e,n.radius().x,n.radius().y),n=i.getText(),i=e.quantify(t,_.utils.getFlags(n.meta.textExpr));n.setText(_.utils.replaceFlags(n.meta.textExpr,i)),n.meta.quantification=i},_.tool.draw.getShadowEllipse=function(e,t){for(var n=0,i=0,r=(void 0!==t&&(n=t.x(),i=t.y()),new L.Group),o=(r.name("shadow"),e.getRound()),a=0;a<o.length;++a){var s=o[a],u=s[0][0],l=s[0][1],s=s[1][0],l=new L.Rect({x:u-n,y:l-i,width:s-u,height:1,fill:"grey",strokeWidth:0,strokeScaleEnabled:!1,opacity:.3,name:"shadow-element"});r.add(l)}return r},_||{}),_=(_.tool=_.tool||{},_.tool.filter=_.tool.filter||{},_.tool.Filter=function(n){this.filterList=null,this.selectedFilter=0;var i=new _.utils.ListenerHandler;function r(e){i.fireEvent(e)}this.activate=function(e){for(var t in this.filterList)e?(this.filterList[t].addEventListener("filterrun",r),this.filterList[t].addEventListener("filter-undo",r)):(this.filterList[t].removeEventListener("filterrun",r),this.filterList[t].removeEventListener("filter-undo",r))},this.setOptions=function(e){for(var t in this.filterList={},e)this.filterList[t]=new e[t](n)},this.getOptionsType=function(){return"instance"},this.init=function(){for(var e in this.filterList)this.filterList[e].init()},this.keydown=function(e){e.context="dwv.tool.Filter",n.onKeydown(e)},this.getEventNames=function(){return["filterrun","filterundo"]},this.addEventListener=function(e,t){i.add(e,t)},this.removeEventListener=function(e,t){i.remove(e,t)}},_.tool.Filter.prototype.getSelectedFilter=function(){return this.selectedFilter},_.tool.Filter.prototype.setFeatures=function(e){if(void 0!==e.filterName){if(!this.hasFilter(e.filterName))throw new Error("Unknown filter: '"+e.filterName+"'");this.selectedFilter&&this.selectedFilter.activate(!1),this.selectedFilter=this.filterList[e.filterName],this.selectedFilter.activate(!0)}var t;void 0!==e.run&&e.run&&(t={},void 0!==e.runArgs&&(t=e.runArgs),this.getSelectedFilter().run(t))},_.tool.Filter.prototype.getFilterList=function(){return this.filterList},_.tool.Filter.prototype.hasFilter=function(e){return this.filterList[e]},_.tool.filter.Threshold=function(t){var n=new _.image.filter.Threshold,i=!0,r=new _.utils.ListenerHandler;function o(e){r.fireEvent(e)}this.activate=function(e){e&&(i=!0)},this.init=function(){},this.run=function(e){n.setMin(e.min),n.setMax(e.max),i&&(n.setOriginalImage(t.getLastImage()),i=!1);e=new _.tool.RunFilterCommand(n,t);e.onExecute=o,e.onUndo=o,e.execute(),t.addToUndoStack(e)},this.addEventListener=function(e,t){r.add(e,t)},this.removeEventListener=function(e,t){r.remove(e,t)}},_.tool.filter.Sharpen=function(n){var i=new _.utils.ListenerHandler;function r(e){i.fireEvent(e)}this.activate=function(e){},this.init=function(){},this.run=function(e){var t=new _.image.filter.Sharpen,t=(t.setOriginalImage(n.getLastImage()),new _.tool.RunFilterCommand(t,n));t.onExecute=r,t.onUndo=r,t.execute(),n.addToUndoStack(t)},this.addEventListener=function(e,t){i.add(e,t)},this.removeEventListener=function(e,t){i.remove(e,t)}},_.tool.filter.Sobel=function(n){var i=new _.utils.ListenerHandler;function r(e){i.fireEvent(e)}this.activate=function(e){},this.init=function(){},_.tool.filter.Sobel.prototype.run=function(e){var t=new _.image.filter.Sobel,t=(t.setOriginalImage(n.getLastImage()),new _.tool.RunFilterCommand(t,n));t.onExecute=r,t.onUndo=r,t.execute(),n.addToUndoStack(t)},this.addEventListener=function(e,t){i.add(e,t)},this.removeEventListener=function(e,t){i.remove(e,t)}},_.tool.RunFilterCommand=function(t,n){this.getName=function(){return"Filter-"+t.getName()},this.execute=function(){n.setLastImage(t.update()),n.render(0);var e={type:"filterrun",id:this.getName()};this.onExecute(e)},this.undo=function(){n.setLastImage(t.getOriginalImage()),n.render(0);var e={type:"filterundo",id:this.getName()};this.onUndo(e)}},_.tool.RunFilterCommand.prototype.onExecute=function(e){},_.tool.RunFilterCommand.prototype.onUndo=function(e){},_||{}),v=(_.tool=_.tool||{},v||{}),_=(_.tool.Floodfill=function(r){function o(e){var t=_.gui.getLayerDetailsFromEvent(e);return{x:(t=r.getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().displayToPlaneIndex(e._x,e._y)).get(0),y:t.get(1)}}function d(e,t,n){return!!(h=y(e,t))&&(e=new _.tool.draw.RoiFactory,(m=e.create(h,a.style)).id(_.math.guid()),(t=n.getActiveDrawLayer()).getDrawController().getCurrentPosGroup().add(m),(i=new _.tool.DrawGroupCommand(m,"floodfill",t.getKonvaLayer())).onExecute=D,i.onUndo=D,i.execute(),r.addToUndoStack(i),!0)}var g,e,s=5,u=0,l=2e3,c=null,x=null,S=null,a=this,i=(this.started=!1,null),m=null,h=null,f=[],n=!1,p=(this.style=new _.gui.Style,new _.utils.ListenerHandler),y=(this.setExtend=function(e){n=e},this.getExtend=function(){return n},function(e,t,n){f=[];var i={data:c.data,width:c.width,height:c.height,bytes:4},r=(x=v.floodFill(i,e.x,e.y,t),x=v.gaussBlurOnlyBorder(x,s),v.traceContours(x));if(0<(r=v.simplifyContours(r,u,l)).length&&r[0].points[0].x){if(n)return r[0].points;for(var o=0,a=r[0].points.length;o<a;o++)f.push(new _.math.Point2D(r[0].points[o].x,r[0].points[o].y));return f}return!1});function D(e){p.fireEvent(e)}this.extend=function(e,t,n){if(!g)throw"'initialpoint' not found. User must click before use extend!";m&&m.destroy();for(var i=n.getActiveViewLayer().getViewController(),r=i.getCurrentIndex(),o=i.getImageSize(),a=S||10,s=r.get(2),u=t||o.get(2);s<u&&d(g,a,n);s++)i.incrementIndex(2);i.setCurrentPosition(r);for(var l=r.get(2),c=e||0;c<l&&d(g,a,n);l--)i.decrementIndex(2);i.setCurrentPosition(r)},this.modifyThreshold=function(i,r){if(r||!m)throw"No shape found";r=m.getChildren(function(e){return"shape"===e.name()})[0],clearTimeout(e),e=setTimeout(function(){if(!(h=y(g,i,!0)))return!1;for(var e=[],t=0,n=h.length;t<n;++t)e.push(h[t].x),e.push(h[t].y);r.setPoints(e),r.getLayer().draw(),a.onThresholdChange(i)},100)},this.onThresholdChange=function(e){},this.mousedown=function(e){var t=_.gui.getLayerDetailsFromEvent(e),t=r.getLayerGroupByDivId(t.groupDivId),n=t.getActiveViewLayer(),i=t.getActiveDrawLayer();(c=n.getImageData())?(a.style.setZoomScale(i.getKonvaLayer().getAbsoluteScale()),a.started=!0,g=o(e),d(g,10,t),a.onThresholdChange(10)):_.logger.error("No image found")},this.mousemove=function(e){a.started&&(e=o(e),S=(S=Math.round(Math.sqrt(Math.pow(g.x-e.x,2)+Math.pow(g.y-e.y,2))/2))<10?10:S-10,a.modifyThreshold(S))},this.mouseup=function(e){var t;a.started=!1,n&&(t=_.gui.getLayerDetailsFromEvent(event),t=r.getLayerGroupByDivId(t.groupDivId),a.extend(t))},this.mouseout=function(e){a.mouseup(e)},this.touchstart=function(e){a.mousedown(e)},this.touchmove=function(e){a.mousemove(e)},this.touchend=function(e){a.mouseup(e)},this.keydown=function(e){e.context="dwv.tool.Floodfill",r.onKeydown(e)},this.activate=function(e){e&&(this.style.setBaseScale(r.getBaseScale()),this.setFeatures({shapeColour:this.style.getLineColour()}))},this.init=function(){},this.getEventNames=function(){return["drawcreate","drawchange","drawmove","drawdelete"]},this.addEventListener=function(e,t){p.add(e,t)},this.removeEventListener=function(e,t){p.remove(e,t)}},_.tool.Floodfill.prototype.setFeatures=function(e){void 0!==e.shapeColour&&this.style.setLineColour(e.shapeColour)},_||{}),L=(_.tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_=(_.tool.draw.defaultFreeHandLabelText="",_.tool.draw.FreeHandFactory=function(){this.getGroupName=function(){return"freeHand-group"},this.getNPoints=function(){},this.getTimeout=function(){return 25}},_.tool.draw.FreeHandFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.FreeHandFactory.prototype.create=function(e,t,n){for(var i=[],r=0;r<e.length;++r)i.push(e[r].getX()),i.push(e[r].getY());var o=new L.Line({points:i,stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape",tension:.5}),a=new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),name:"text"}),s="",s=void 0!==_.tool.draw.freeHandLabelText?_.tool.draw.freeHandLabelText:_.tool.draw.defaultFreeHandLabelText,s=(a.setText(s),a.meta={textExpr:s,quantification:{}},new L.Label({x:e[0].getX(),y:e[0].getY()+t.scale(10),scale:t.applyZoomScale(1),visible:0!==s.length,name:"label"})),a=(s.add(a),s.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),new L.Group);return a.name(this.getGroupName()),a.add(s),a.add(o),a.visible(!0),a},_.tool.draw.FreeHandFactory.prototype.getAnchors=function(e,t){for(var n=e.points(),i=[],r=0;r<n.length;r+=2){var o=n[r]+e.x(),a=n[r+1]+e.y(),s=r;i.push(_.tool.draw.getDefaultAnchor(o,a,s,t))}return i},_.tool.draw.FreeHandFactory.prototype.update=function(t,e,n){var i=t.getParent(),r=i.getChildren(function(e){return"shape"===e.name()})[0],o=i.getChildren(function(e){return"label"===e.name()})[0],i=i.getChildren(function(e){return e.id()===t.id()})[0],i=(i.x(t.x()),i.y(t.y()),r.points()),a=(i[t.id()]=t.x()-r.x(),i[t.id()+1]=t.y()-r.y(),r.points(i.concat()),o.getText()),a=(a.setText(a.meta.textExpr),{x:i[0]+r.x(),y:i[1]+r.y()+e.scale(10)});o.position(a)},_||{});_.tool=_.tool||{},_.tool.Livewire=function(u){var l=this,c=(this.started=!1,null),d=null,g=(this.style=new _.gui.Style,new _.math.Path),x=new _.math.Path,S=[],n=new _.utils.ListenerHandler;function r(e){for(var t=e.get(1),n=0;n<t;++n)S[n]=[]}var m=new _.math.Scissors;function o(){e({type:"drawcreate",id:d.id()}),c.onExecute=e,c.onUndo=e,u.addToUndoStack(c),l.started=!1}function e(e){n.fireEvent(e)}this.mousedown=function(e){var t=_.gui.getLayerDetailsFromEvent(e),t=u.getLayerGroupByDivId(t.groupDivId),n=t.getActiveViewLayer(),i=n.getViewController().getImageSize(),n=n.displayToPlaneIndex(e._x,e._y);l.started?Math.abs(n.get(0)-l.x0)<5&&Math.abs(n.get(1)-l.y0)<5?o():(g=x,r(i),e={x:n.get(0),y:n.get(1)},m.doTraining(e),g.addControlPoint(x.getPoint(0))):(l.started=!0,l.x0=n.get(0),l.y0=n.get(1),g=new _.math.Path,x=new _.math.Path,r(i),d=null,e=t.getActiveDrawLayer(),l.style.setZoomScale(e.getKonvaLayer().getAbsoluteScale()),i={x:n.get(0),y:n.get(1)},m.doTraining(i),t=new _.math.Point2D(n.get(0),n.get(1)),g.addPoint(t),g.addControlPoint(t))},this.mousemove=function(e){if(l.started){for(var t,n=_.gui.getLayerDetailsFromEvent(e),n=u.getLayerGroupByDivId(n.groupDivId),e=n.getActiveViewLayer().displayToPlaneIndex(e._x,e._y),i={x:e.get(0),y:e.get(1)},r=(m.setPoint(i),!1);!S[i.y][i.x]&&!r;)if(0===(t=m.doWork()).length)r=!0;else for(var o=0;o<t.length-1;o+=2){var a=t[o],s=t[o+1];S[a.y][a.x]=s}for(x=new _.math.Path,r=!1;i&&!r;)x.addPoint(new _.math.Point2D(i.x,i.y)),S[i.y]&&S[i.y][i.x]?i=S[i.y][i.x]:r=!0;x.appenPath(g),d&&d.destroy();e=new _.tool.draw.RoiFactory,e=((d=e.create(x.pointArray,l.style)).id(_.math.guid()),n.getActiveDrawLayer());e.getDrawController().getCurrentPosGroup().add(d),(c=new _.tool.DrawGroupCommand(d,"livewire",e.getKonvaLayer())).execute()}},this.mouseup=function(e){},this.mouseout=function(e){l.mouseup(e)},this.dblclick=function(e){o()},this.touchstart=function(e){l.mousedown(e)},this.touchmove=function(e){l.mousemove(e)},this.touchend=function(e){l.mouseup(e)},this.keydown=function(e){e.context="dwv.tool.Livewire",u.onKeydown(e)},this.activate=function(e){var t;e&&(t=(e=u.getActiveLayerGroup().getActiveViewLayer()).getViewController().getImageSize(),m.setDimensions(t.get(0),t.get(1)),m.setData(e.getImageData().data),this.style.setBaseScale(u.getBaseScale()),this.setFeatures({shapeColour:this.style.getLineColour()}))},this.init=function(){},this.getEventNames=function(){return["drawcreate","drawchange","drawmove","drawdelete"]},this.addEventListener=function(e,t){n.add(e,t)},this.removeEventListener=function(e,t){n.remove(e,t)}},_.tool.Livewire.prototype.setFeatures=function(e){void 0!==e.shapeColour&&this.style.setLineColour(e.shapeColour)};var _}(_=_||{}).tool=_.tool||{},_.tool.Opacity=function(r){var o=this,t=(this.started=!1,new _.tool.ScrollWheel(r));this.mousedown=function(e){o.started=!0,o.x0=e._x,o.y0=e._y},this.mousemove=function(e){var t,n,i;o.started&&(t=e._x-o.x0,15<Math.abs(t)&&(n=_.gui.getLayerDetailsFromEvent(e),i=(n=r.getLayerGroupByDivId(n.groupDivId).getActiveViewLayer()).getOpacity(),n.setOpacity(i+t/200),n.draw(),o.x0=e._x))},this.mouseup=function(e){o.started&&(o.started=!1)},this.mouseout=function(e){o.mouseup(e)},this.touchstart=function(e){o.mousedown(e)},this.touchmove=function(e){o.mousemove(e)},this.touchend=function(e){o.mouseup(e)},this.wheel=function(e){t.wheel(e)},this.keydown=function(e){e.context="dwv.tool.Opacity",r.onKeydown(e)},this.activate=function(e){},this.init=function(){}};var _,L=((_=_||{}).tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{});_.tool.draw.defaultProtractorLabelText="{angle}",_.tool.draw.ProtractorFactory=function(){this.getGroupName=function(){return"protractor-group"},this.getNPoints=function(){return 3},this.getTimeout=function(){return 500}},_.tool.draw.ProtractorFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.ProtractorFactory.prototype.create=function(t,e,n){for(var i=new _.math.Line(t[0],t[1]),r=[],o=0;o<t.length;++o)r.push(t[o].getX()),r.push(t[o].getY());var a,s,u,l,c,d,g,x=new L.Line({points:r,stroke:e.getLineColour(),strokeWidth:e.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),S=new L.Group;return S.name(this.getGroupName()),3===t.length&&(a=new _.math.Line(t[1],t[2]),x.hitFunc(function(e){e.beginPath(),e.moveTo(t[0].getX(),t[0].getY()),e.lineTo(t[1].getX(),t[1].getY()),e.lineTo(t[2].getX(),t[2].getY()),e.closePath(),e.fillStrokeShape(this)}),s=_.math.getAngle(i,a),u=i.getInclination(),180<s&&(u+=s=360-s),l=new L.Text({fontSize:e.getFontSize(),fontFamily:e.getFontFamily(),fill:e.getLineColour(),padding:e.getTextPadding(),shadowColor:e.getShadowLineColour(),shadowOffset:e.getShadowOffset(),name:"text"}),g="",g=void 0!==_.tool.draw.protractorLabelText?_.tool.draw.protractorLabelText:_.tool.draw.defaultProtractorLabelText,c={angle:{value:s,unit:_.i18n("unit.degree")}},l.setText(_.utils.replaceFlags(g,c)),l.meta={textExpr:g,quantification:c},c=(i.getMidpoint().getX()+a.getMidpoint().getX())/2,d=(i.getMidpoint().getY()+a.getMidpoint().getY())/2,(c=new L.Label({x:c,y:d-e.applyZoomScale(15).y,scale:e.applyZoomScale(1),visible:0!==g.length,name:"label"})).add(l),c.add(new L.Tag({fill:e.getLineColour(),opacity:e.getTagOpacity()})),d=33*Math.min(i.getLength(),a.getLength())/100,g=new L.Arc({innerRadius:d,outerRadius:d,stroke:e.getLineColour(),strokeWidth:e.getStrokeWidth(),strokeScaleEnabled:!1,angle:s,rotation:-u,x:t[1].getX(),y:t[1].getY(),name:"shape-arc"}),S.add(c),S.add(g)),S.add(x),S.visible(!0),S},_.tool.draw.ProtractorFactory.prototype.getAnchors=function(e,t){var n=e.points(),i=[];return i.push(_.tool.draw.getDefaultAnchor(n[0]+e.x(),n[1]+e.y(),"begin",t)),i.push(_.tool.draw.getDefaultAnchor(n[2]+e.x(),n[3]+e.y(),"mid",t)),i.push(_.tool.draw.getDefaultAnchor(n[4]+e.x(),n[5]+e.y(),"end",t)),i},_.tool.draw.ProtractorFactory.prototype.update=function(e,t,n){var i=e.getParent(),r=i.getChildren(function(e){return"shape"===e.name()})[0],o=i.getChildren(function(e){return"label"===e.name()})[0],a=i.getChildren(function(e){return"shape-arc"===e.name()})[0],s=i.getChildren(function(e){return"begin"===e.id()})[0],u=i.getChildren(function(e){return"mid"===e.id()})[0],l=i.getChildren(function(e){return"end"===e.id()})[0];switch(e.id()){case"begin":s.x(e.x()),s.y(e.y());break;case"mid":u.x(e.x()),u.y(e.y());break;case"end":l.x(e.x()),l.y(e.y())}var c=s.x()-r.x(),d=s.y()-r.y(),g=u.x()-r.x(),x=u.y()-r.y(),S=l.x()-r.x(),m=l.y()-r.y(),i=(r.points([c,d,g,x,S,m]),r.hitFunc(function(e){e.beginPath(),e.moveTo(c,d),e.lineTo(g,x),e.lineTo(S,m),e.closePath(),e.fillStrokeShape(this)}),new _.math.Point2D(s.x(),s.y())),r=new _.math.Point2D(u.x(),u.y()),h=new _.math.Point2D(l.x(),l.y()),i=new _.math.Line(i,r),r=new _.math.Line(r,h),h=_.math.getAngle(i,r),f=i.getInclination(),p=(180<h&&(f+=h=360-h),o.getText()),y={angle:{value:h,unit:_.i18n("unit.degree")}};p.setText(_.utils.replaceFlags(p.meta.textExpr,y)),p.meta.quantification=y;p={x:(i.getMidpoint().getX()+r.getMidpoint().getX())/2,y:(i.getMidpoint().getY()+r.getMidpoint().getY())/2-t.applyZoomScale(15).y},o.position(p),y=33*Math.min(i.getLength(),r.getLength())/100,a.innerRadius(y),a.outerRadius(y),a.angle(h),a.rotation(-f),t={x:u.x(),y:u.y()};a.position(t)};var _,L=((_=_||{}).tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{});_.tool.draw.defaultRectangleLabelText="{surface}",_.tool.draw.RectangleFactory=function(){this.getGroupName=function(){return"rectangle-group"},this.getNPoints=function(){return 2},this.getTimeout=function(){return 0}},_.tool.draw.RectangleFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.RectangleFactory.prototype.create=function(e,t,n){var i,e=new _.math.Rectangle(e[0],e[1]),r=new L.Rect({x:e.getBegin().getX(),y:e.getBegin().getY(),width:e.getWidth(),height:e.getHeight(),stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),o=new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"}),a="",a=void 0!==_.tool.draw.rectangleLabelText?_.tool.draw.rectangleLabelText:_.tool.draw.defaultRectangleLabelText,n=e.quantify(n,_.utils.getFlags(a)),n=(o.setText(_.utils.replaceFlags(a,n)),o.meta={textExpr:a,quantification:n},new L.Label({x:e.getBegin().getX(),y:e.getEnd().getY(),scale:t.applyZoomScale(1),visible:0!==a.length,name:"label"})),a=(n.add(o),n.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),_.tool.draw.debug&&(i=_.tool.draw.getShadowRectangle(e)),new L.Group);return a.name(this.getGroupName()),i&&a.add(i),a.add(n),a.add(r),a.visible(!0),a},_.tool.draw.RectangleFactory.prototype.getAnchors=function(e,t){var n=e.x(),i=e.y(),r=e.width(),e=e.height(),o=[];return o.push(_.tool.draw.getDefaultAnchor(n,i,"topLeft",t)),o.push(_.tool.draw.getDefaultAnchor(n+r,i,"topRight",t)),o.push(_.tool.draw.getDefaultAnchor(n+r,i+e,"bottomRight",t)),o.push(_.tool.draw.getDefaultAnchor(n,i+e,"bottomLeft",t)),o},_.tool.draw.RectangleFactory.prototype.update=function(e,t,n){var i,r=e.getParent(),o=r.getChildren(function(e){return"shape"===e.name()})[0],a=r.getChildren(function(e){return"label"===e.name()})[0],s=r.getChildren(function(e){return"topLeft"===e.id()})[0],u=r.getChildren(function(e){return"topRight"===e.id()})[0],l=r.getChildren(function(e){return"bottomRight"===e.id()})[0],c=r.getChildren(function(e){return"bottomLeft"===e.id()})[0];switch(_.tool.draw.debug&&(i=r.getChildren(function(e){return"shadow"===e.name()})[0]),e.id()){case"topLeft":s.x(e.x()),s.y(e.y()),u.y(e.y()),c.x(e.x());break;case"topRight":u.x(e.x()),u.y(e.y()),s.y(e.y()),l.x(e.x());break;case"bottomRight":l.x(e.x()),l.y(e.y()),c.y(e.y()),u.x(e.x());break;case"bottomLeft":c.x(e.x()),c.y(e.y()),l.y(e.y()),s.x(e.x());break;default:_.logger.error("Unhandled anchor id: "+e.id())}o.position(s.position());var d,g=u.x()-s.x(),x=c.y()-s.y(),o=(g&&x&&o.size({width:g,height:x}),new _.math.Point2D(r.x()+s.x(),r.y()+s.y())),g=new _.math.Point2D(r.x()+l.x(),r.y()+l.y()),x=new _.math.Rectangle(o,g),o=(i&&(g=(o=x.getRound()).max.getX()-o.min.getX(),d=o.max.getY()-o.min.getY(),i.position({x:o.min.getX()-r.x(),y:o.min.getY()-r.y()}),i.size({width:g,height:d})),{x:x.getBegin().getX()-r.x(),y:x.getEnd().getY()-r.y()});a.position(o),_.tool.draw.updateRectangleQuantification(r,n)},_.tool.draw.RectangleFactory.prototype.updateQuantification=function(e,t){_.tool.draw.updateRectangleQuantification(e,t)},_.tool.draw.updateRectangleQuantification=function(e,t){var n=e.getChildren(function(e){return"shape"===e.name()})[0],i=e.getChildren(function(e){return"label"===e.name()})[0],e=new _.math.Point2D(e.x()+n.x(),e.y()+n.y()),n=new _.math.Point2D(e.getX()+n.width(),e.getY()+n.height()),e=new _.math.Rectangle(e,n),n=i.getText(),i=e.quantify(t,_.utils.getFlags(n.meta.textExpr));n.setText(_.utils.replaceFlags(n.meta.textExpr,i)),n.meta.quantification=i},_.tool.draw.getShadowRectangle=function(e){var e=e.getRound(),t=e.max.getX()-e.min.getX(),n=e.max.getY()-e.min.getY();return new L.Rect({x:e.min.getX(),y:e.min.getY(),width:t,height:n,fill:"grey",strokeWidth:0,strokeScaleEnabled:!1,opacity:.3,name:"shadow"})};var _,L=((_=_||{}).tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{});_.tool.draw.defaultRoiLabelText="",_.tool.draw.RoiFactory=function(){this.getGroupName=function(){return"roi-group"},this.getNPoints=function(){},this.getTimeout=function(){return 100}},_.tool.draw.RoiFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.RoiFactory.prototype.create=function(e,t,n){for(var i=new _.math.ROI,r=(i.addPoints(e),[]),o=0;o<i.getLength();++o)r.push(i.getPoint(o).getX()),r.push(i.getPoint(o).getY());var e=new L.Line({points:r,stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape",closed:!0}),a=new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),name:"text"}),s="",s=void 0!==_.tool.draw.roiLabelText?_.tool.draw.roiLabelText:_.tool.draw.defaultRoiLabelText,s=(a.setText(s),a.meta={textExpr:s,quantification:{}},new L.Label({x:i.getPoint(0).getX(),y:i.getPoint(0).getY()+t.scale(10),scale:t.applyZoomScale(1),visible:0!==s.length,name:"label"})),a=(s.add(a),s.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),new L.Group);return a.name(this.getGroupName()),a.add(s),a.add(e),a.visible(!0),a},_.tool.draw.RoiFactory.prototype.getAnchors=function(e,t){for(var n=e.points(),i=[],r=0;r<n.length;r+=2){var o=n[r]+e.x(),a=n[r+1]+e.y(),s=r;i.push(_.tool.draw.getDefaultAnchor(o,a,s,t))}return i},_.tool.draw.RoiFactory.prototype.update=function(t,e,n){var i=t.getParent(),r=i.getChildren(function(e){return"shape"===e.name()})[0],o=i.getChildren(function(e){return"label"===e.name()})[0],i=i.getChildren(function(e){return e.id()===t.id()})[0],i=(i.x(t.x()),i.y(t.y()),r.points()),a=(i[t.id()]=t.x()-r.x(),i[t.id()+1]=t.y()-r.y(),r.points(i),o.getText()),a=(a.setText(a.meta.textExpr),{x:i[0]+r.x(),y:i[1]+r.y()+e.scale(10)});o.position(a)};var _,L=((_=_||{}).tool=_.tool||{},_.tool.draw=_.tool.draw||{},L||{}),_,_,_,_,_,_;_.tool.draw.defaultRulerLabelText="{length}",_.tool.draw.RulerFactory=function(){this.getGroupName=function(){return"ruler-group"},this.getNPoints=function(){return 2},this.getTimeout=function(){return 0}},_.tool.draw.RulerFactory.prototype.isFactoryGroup=function(e){return this.getGroupName()===e.name()},_.tool.draw.RulerFactory.prototype.create=function(e,t,n){var i=new _.math.Line(e[0],e[1]),r=new L.Line({points:[i.getBegin().getX(),i.getBegin().getY(),i.getEnd().getX(),i.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),o=t.scale(10),a=_.math.getPerpendicularLine(i,e[0],o),s=new L.Line({points:[a.getBegin().getX(),a.getBegin().getY(),a.getEnd().getX(),a.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape-tick0"}),u=_.math.getPerpendicularLine(i,e[1],o),e=new L.Line({points:[u.getBegin().getX(),u.getBegin().getY(),u.getEnd().getX(),u.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape-tick1"}),o=(r.hitFunc(function(e){e.beginPath(),e.moveTo(a.getBegin().getX(),a.getBegin().getY()),e.lineTo(a.getEnd().getX(),a.getEnd().getY()),e.lineTo(u.getEnd().getX(),u.getEnd().getY()),e.lineTo(u.getBegin().getX(),u.getBegin().getY()),e.closePath(),e.fillStrokeShape(this)}),new L.Text({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"})),l="",l=void 0!==_.tool.draw.rulerLabelText?_.tool.draw.rulerLabelText:_.tool.draw.defaultRulerLabelText,n=i.quantify(n,_.utils.getFlags(l)),n=(o.setText(_.utils.replaceFlags(l,n)),o.meta={textExpr:l,quantification:n},i.getBegin().getX()>i.getEnd().getX()?0:-1),c=i.getBegin().getY()>i.getEnd().getY()?-1:0,n=new L.Label({x:i.getEnd().getX()+n*o.width(),y:i.getEnd().getY()+c*t.applyZoomScale(15).y,scale:t.applyZoomScale(1),visible:0!==l.length,name:"label"}),i=(n.add(o),n.add(new L.Tag({fill:t.getLineColour(),opacity:t.getTagOpacity()})),new L.Group);return i.name(this.getGroupName()),i.add(n),i.add(s),i.add(e),i.add(r),i.visible(!0),i},_.tool.draw.RulerFactory.prototype.getAnchors=function(e,t){var n=e.points(),i=[];return i.push(_.tool.draw.getDefaultAnchor(n[0]+e.x(),n[1]+e.y(),"begin",t)),i.push(_.tool.draw.getDefaultAnchor(n[2]+e.x(),n[3]+e.y(),"end",t)),i},_.tool.draw.RulerFactory.prototype.update=function(e,t,n){var i=e.getParent(),r=i.getChildren(function(e){return"shape"===e.name()})[0],o=i.getChildren(function(e){return"shape-tick0"===e.name()})[0],a=i.getChildren(function(e){return"shape-tick1"===e.name()})[0],s=i.getChildren(function(e){return"label"===e.name()})[0],u=i.getChildren(function(e){return"begin"===e.id()})[0],l=i.getChildren(function(e){return"end"===e.id()})[0];switch(e.id()){case"begin":u.x(e.x()),u.y(e.y());break;case"end":l.x(e.x()),l.y(e.y())}var i=u.x()-r.x(),c=u.y()-r.y(),d=l.x()-r.x(),g=l.y()-r.y(),x=(r.points([i,c,d,g]),new _.math.Point2D(u.x(),u.y())),S=new _.math.Point2D(l.x(),l.y()),x=new _.math.Line(x,S),S=new _.math.Point2D(i,c),i=new _.math.Point2D(d,g),m=_.math.getPerpendicularLine(x,S,t.scale(10)),h=(o.points([m.getBegin().getX(),m.getBegin().getY(),m.getEnd().getX(),m.getEnd().getY()]),_.math.getPerpendicularLine(x,i,t.scale(10))),c=(a.points([h.getBegin().getX(),h.getBegin().getY(),h.getEnd().getX(),h.getEnd().getY()]),r.hitFunc(function(e){e.beginPath(),e.moveTo(m.getBegin().getX(),m.getBegin().getY()),e.lineTo(m.getEnd().getX(),m.getEnd().getY()),e.lineTo(h.getEnd().getX(),h.getEnd().getY()),e.lineTo(h.getBegin().getX(),h.getBegin().getY()),e.closePath(),e.fillStrokeShape(this)}),s.getText()),d=x.quantify(n,_.utils.getFlags(c.meta.textExpr)),g=(c.setText(_.utils.replaceFlags(c.meta.textExpr,d)),c.meta.quantification=d,x.getBegin().getX()>x.getEnd().getX()?0:-1),S=x.getBegin().getY()>x.getEnd().getY()?-1:0,o={x:x.getEnd().getX()+g*c.width(),y:x.getEnd().getY()+S*t.applyZoomScale(15).y};s.position(o)},(_=_||{}).tool=_.tool||{},_.tool.Scroll=function(a){var s=this,t=(this.started=!1,null),n=new _.tool.ScrollWheel(a),u=!1;function l(){var e=document.getElementById("scroll-tooltip");e&&e.remove()}this.mousedown=function(e){l();var t=_.gui.getLayerDetailsFromEvent(e),t=a.getLayerGroupByDivId(t.groupDivId).getActiveViewLayer(),n=t.getViewController(),t=(n.isPlaying()&&n.stop(),s.started=!0,s.x0=e._x,s.y0=e._y,t.displayToPlanePos(e._x,e._y)),e=n.getPositionFromPlanePoint(t.x,t.y);n.setCurrentPosition(e)},this.mousemove=function(e){var t,n,i,r,o;s.started?(t=_.gui.getLayerDetailsFromEvent(e),t=a.getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().getViewController(),i=e._y-s.y0,(n=15<Math.abs(i))&&t.canScroll()&&(0<i?t.decrementScrollIndex():t.incrementScrollIndex()),i=e._x-s.x0,r=15<Math.abs(i),o=t.getImageSize(),r&&o.moreThanOne(3)&&(0<i?t.incrementIndex(3):t.decrementIndex(3)),r&&(s.x0=e._x),n&&(s.y0=e._y)):u&&(o=e,l(),i=_.gui.getLayerDetailsFromEvent(o),t=(i=a.getLayerGroupByDivId(i.groupDivId).getActiveViewLayer()).getViewController(),r=i.displayToPlanePos(o._x,o._y),r=t.getPositionFromPlanePoint(r.x,r.y),void 0!==(r=t.getRescaledImageValue(r))&&((n=document.createElement("span")).id="scroll-tooltip",document.getElementById(i.getId()).parentElement.appendChild(n),n.style.left=o._x+10+"px",n.style.top=o._y+10+"px",i=_.utils.precisionRound(r,3),void 0!==t.getPixelUnit()&&(i+=" "+t.getPixelUnit()),n.appendChild(document.createTextNode(i))))},this.mouseup=function(e){s.started&&(s.started=!1)},this.mouseout=function(e){s.mouseup(e),l()},this.touchstart=function(e){t=setTimeout(s.dblclick,500),s.mousedown(e)},this.touchmove=function(e){null!==t&&(clearTimeout(t),t=null),s.mousemove(e)},this.touchend=function(e){null!==t&&(clearTimeout(t),t=null),s.mouseup(e)},this.wheel=function(e){n.wheel(e)},this.keydown=function(e){e.context="dwv.tool.Scroll",a.onKeydown(e)},this.dblclick=function(e){e=_.gui.getLayerDetailsFromEvent(e);a.getLayerGroupByDivId(e.groupDivId).getActiveViewLayer().getViewController().play()},this.activate=function(e){e||l()},this.setFeatures=function(e){void 0!==e.displayTooltip&&(u=e.displayTooltip)},this.init=function(){}},(_=_||{}).tool=_.tool||{},_.tool.ScrollWheel=function(i){var r=0;this.wheel=function(e){var t,n=52;1===e.deltaMode&&(n=5.99),r+=e.deltaY,Math.abs(r)<n||(r=0,n=e.deltaY<0,e=_.gui.getLayerDetailsFromEvent(e),(t=(e=i.getLayerGroupByDivId(e.groupDivId).getActiveViewLayer().getViewController()).getImageSize()).canScroll3D()?n?e.incrementScrollIndex():e.decrementScrollIndex():t.moreThanOne(3)&&(n?e.incrementIndex(3):e.decrementIndex(3)))}},(_=_||{}).tool=_.tool||{},_.tool.UndoStack=function(){var t=[],n=0,i=new _.utils.ListenerHandler;function r(e){i.fireEvent(e)}this.getStackSize=function(){return t.length},this.getCurrentStackIndex=function(){return n},this.add=function(e){(t=t.slice(0,n)).push(e),++n,r({type:"undoadd",command:e.getName()})},this.undo=function(){0<n&&(t[--n].undo(),r({type:"undo",command:t[n].getName()}))},this.redo=function(){n<t.length&&(t[n].execute(),r({type:"redo",command:t[n].getName()}),++n)},this.addEventListener=function(e,t){i.add(e,t)},this.removeEventListener=function(e,t){i.remove(e,t)}},(_=_||{}).tool=_.tool||{},_.tool.WindowLevel=function(s){var u=this,t=(this.started=!1,new _.tool.ScrollWheel(s));this.mousedown=function(e){u.started=!0,u.x0=e._x,u.y0=e._y},this.mousemove=function(e){var t,n,i,r,o,a;u.started&&(t=_.gui.getLayerDetailsFromEvent(e),t=s.getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().getViewController(),n=e._x-u.x0,a=u.y0-e._y,i=.01*((i=t.getImageRescaledDataRange()).max-i.min),o=parseInt(t.getWindowLevel().center,10),r=parseInt(t.getWindowLevel().width,10),o=o+Math.round(a*i),a=r+Math.round(n*i),a=_.image.validateWindowWidth(a),t.addWindowLevelPresets({manual:{wl:[new _.image.WindowLevel(o,a)],name:"manual"}}),t.setWindowLevelPreset("manual"),u.x0=e._x,u.y0=e._y)},this.mouseup=function(e){u.started&&(u.started=!1)},this.mouseout=function(e){u.mouseup(e)},this.touchstart=function(e){u.mousedown(e)},this.touchmove=function(e){u.mousemove(e)},this.touchend=function(e){u.mouseup(e)},this.dblclick=function(e){var t=_.gui.getLayerDetailsFromEvent(e),t=s.getLayerGroupByDivId(t.groupDivId).getActiveViewLayer(),e=t.displayToPlaneIndex(e._x,e._y),n=t.getViewController(),t=s.getImage(t.getDataIndex());n.setWindowLevel(parseInt(t.getRescaledValueAtIndex(n.getCurrentIndex().getWithNew2D(e.get(0),e.get(1))),10),parseInt(n.getWindowLevel().width,10))},this.wheel=function(e){t.wheel(e)},this.keydown=function(e){e.context="dwv.tool.WindowLevel",s.onKeydown(e)},this.activate=function(e){},this.init=function(){}},(_=_||{}).tool=_.tool||{},_.tool.ZoomAndPan=function(a){var s=this;this.started=!1,this.mousedown=function(e){s.started=!0,s.x0=e._x,s.y0=e._y},this.twotouchdown=function(e){s.started=!0,s.x0=e._x,s.y0=e._y;var t=new _.math.Point2D(e._x,e._y),e=new _.math.Point2D(e._x1,e._y1);s.line0=new _.math.Line(t,e),s.midPoint=s.line0.getMidpoint()},this.mousemove=function(e){var t,n,i,r,o;s.started&&(o=e._x-s.x0,t=e._y-s.y0,n=_.gui.getLayerDetailsFromEvent(e),i=(r=(n=a.getLayerGroupByDivId(n.groupDivId)).getActiveViewLayer()).getViewController(),r=r.displayToPlaneScale(o,t),o=i.getOffset3DFromPlaneOffset(r),n.addTranslation({x:o.getX(),y:o.getY(),z:o.getZ()}),n.draw(),s.x0=e._x,s.y0=e._y)},this.twotouchmove=function(e){var t,n,i,r;s.started&&(i=new _.math.Point2D(e._x,e._y),t=new _.math.Point2D(e._x1,e._y1),i=new _.math.Line(i,t).getLength()/s.line0.getLength(),t=_.gui.getLayerDetailsFromEvent(e),n=(r=(t=a.getLayerGroupByDivId(t.groupDivId)).getActiveViewLayer()).getViewController(),1==i?(e=e._y-s.y0,Math.abs(e)<15||n.getImageSize().canScroll(2)&&(0<e?n.incrementIndex(2):n.decrementIndex(2))):(e=(i-1)/10,Math.abs(e)%.1<=.05&&(i=r.displayToMainPlanePos(s.midPoint.getX(),s.midPoint.getY()),r=n.getPlanePositionFromPlanePoint(i),t.addScale(e,r),t.draw())))},this.mouseup=function(e){s.started&&(s.started=!1)},this.mouseout=function(e){s.mouseup(e)},this.touchstart=function(e){var t=e.targetTouches;1===t.length?s.mousedown(e):2===t.length&&s.twotouchdown(e)},this.touchmove=function(e){var t=e.targetTouches;1===t.length?s.mousemove(e):2===t.length&&s.twotouchmove(e)},this.touchend=function(e){s.mouseup(e)},this.wheel=function(e){var t=-e.deltaY/500,n=_.gui.getLayerDetailsFromEvent(e),n=a.getLayerGroupByDivId(n.groupDivId),i=n.getActiveViewLayer(),r=i.getViewController(),i=i.displayToMainPlanePos(e._x,e._y),e=r.getPlanePositionFromPlanePoint(i);n.addScale(t,e),n.draw()},this.keydown=function(e){e.context="dwv.tool.ZoomAndPan",a.onKeydown(e)},this.activate=function(e){}},_.tool.ZoomAndPan.prototype.init=function(){},(_=_||{}).utils=_.utils||{},_.utils.arraySortEquals=function(e,t){if(null===e||null===t||void 0===e||void 0===t)return!1;e=e.slice().sort(),t=t.slice().sort();return _.utils.arrayEquals(e,t)},_.utils.arrayEquals=function(e,n){return null!==e&&null!==n&&void 0!==e&&void 0!==n&&(e.length===n.length&&e.every(function(e,t){return e===n[t]}))},_.utils.uint8ArrayToString=function(e){return String.fromCharCode.apply(String,e)},_.utils.findInArraySubset=function(e,t,n,i){(void 0===n||n<0||n>=e.length)&&(n=0),(void 0===i||i<=n||i>e.length)&&(i=e.length);for(var r=n;r<i;++r)if(t(e[r],r,e))return r},_.utils.getFindArrayInArrayCallback=function(r){return function(e,t,n){for(var i=0;i<r.length;++i)if(n[t+i]!==r[i])return!1;return!0}},_.utils.parseMultipart=function(e){var t=new Uint8Array(e),n=[];if(0===t.length)return n;var e=new Uint8Array([13,10,13,10]),i=_.utils.getFindArrayInArrayCallback(e),r=_.utils.findInArraySubset(t,i,0);if(void 0===r)throw new Error("Can't find the end of the first multipart header");for(var o,e=t.slice(0,r),a=_.utils.uint8ArrayToString(e).split("\r\n"),s=0;s<a.length;++s)if("-"===a[s][0]&&"-"===a[s][1]){o=a[s];break}if(void 0===o)throw new Error("Can't find the boundary between multi-parts");for(var e=_.utils.stringToUint8Array(o),u=_.utils.getFindArrayInArrayCallback(e),l=o.length,c=_.utils.findInArraySubset(t,u,0);void 0!==r;){for(var d={},g=t.slice(c+l,r),x=_.utils.uint8ArrayToString(g).split("\r\n"),S=0;S<x.length;++S){var m,h=x[S],f=h.indexOf(":");-1!==f&&(m=h.substring(0,f).trim(),h=h.substring(f+1).trim(),d[m]=h)}if(void 0===(c=_.utils.findInArraySubset(t,u,r)))break;var g=r+4,p=c-2;d.data=g<p?t.slice(g,p).buffer:new Uint8Array,n.push(d),r=_.utils.findInArraySubset(t,i,c+l)}return n},_.utils.buildMultipart=function(e,t){for(var n="\r\n",i=0,r=[],o=0;o<e.length;++o){for(var a="",s=(0!==o&&(a+=n),a+="--"+t+n,Object.keys(e[o])),u=0;u<s.length;++u){var l=s[u];"data"!==l&&(a+=l+": "+e[o][l]+n)}a+=n;var c=_.utils.stringToUint8Array(a);r.push(c),i+=c.byteLength+e[o].data.byteLength}for(var d=_.utils.stringToUint8Array("\r\n--"+t+"--"+n),g=new Uint8Array(i+d.byteLength),x=0,S=0;S<e.length;++S)g.set(r[S],x),x+=r[S].byteLength,g.set(new Uint8Array(e[S].data),x),x+=e[S].data.byteLength;return g.set(d,x),g}}return(_=_||{}).utils=_.utils||{},_.utils.isEqualRgb=function(e,t){return null!==e&&null!==t&&void 0!==e&&void 0!==t&&e.r===t.r&&e.g===t.g&&e.b===t.b},_.utils.ybrToRgb=function(e,t,n){return{r:e+1.402*(n-128),g:e-.34414*(t-128)-.71414*(n-128),b:e+1.772*(t-128)}},_.utils.hexToRgb=function(e){return{r:parseInt(e.substring(1,3),16),g:parseInt(e.substring(3,5),16),b:parseInt(e.substring(5,7),16)}},_.utils.rgbToHex=function(e){return"#"+((1<<24)+(e.r<<16)+(e.g<<8)+e.b).toString(16).slice(1)},_.utils.getBrightness=function(e){return.001172549*e.r+.002301961*e.g+447059e-9*e.b},_.utils.isDarkColour=function(e){return _.utils.getBrightness(_.utils.hexToRgb(e))<.5},_.utils.getShadowColour=function(e){return _.utils.isDarkColour(e)?"#fff":"#000"},_.utils.uintLabToLab=function(e){return{l:.001525902*e.l,a:.003891051*e.a-128,b:.003891051*e.b-128}},_.utils.labToUintLab=function(e){return{l:655.35*e.l,a:257*e.a+32896,b:257*e.b+32896}},_.utils.d65={x:95.0489,y:100,z:108.884},_.utils.cielabToCiexyz=function(e){function t(e){return.206896552<e?Math.pow(e,3):.128418549*e-.017712903}var n=_.utils.d65,i=(e.l+16)/116;return{x:n.x*t(i+e.a/500),y:n.y*t(i),z:n.z*t(i-e.b/200)}},_.utils.ciexyzToCielab=function(e){function t(e){return.008856452<e?Math.pow(e,.333333333):7.787037037*e+.137931034}var n=_.utils.d65,i=t(e.y/n.y);return{l:116*i-16,a:500*(t(e.x/n.x)-i),b:200*(i-t(e.z/n.z))}},_.utils.ciexyzToSrgb=function(e){function t(e){var t=null,t=e<=.0031308?12.92*e:1.055*Math.pow(e,.416666667)-.055;return Math.min(1,Math.max(0,t))}var n=e.x/100,i=e.y/100,e=e.z/100;return{r:Math.round(255*t(3.2406*n-1.5372*i-.4986*e)),g:Math.round(255*t(-.9689*n+1.8758*i+.0415*e)),b:Math.round(255*t(.0557*n-.204*i+1.057*e))}},_.utils.srgbToCiexyz=function(e){function t(e){return e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}var n=t(e.r/255),i=t(e.g/255),e=t(e.b/255);return{x:100*(.4124*n+.3576*i+.1805*e),y:100*(.2126*n+.7152*i+.0722*e),z:100*(.0193*n+.1192*i+.9505*e)}},_.utils.cielabToSrgb=function(e){return _.utils.ciexyzToSrgb(_.utils.cielabToCiexyz(e))},_.utils.srgbToCielab=function(e){return _.utils.ciexyzToCielab(_.utils.srgbToCiexyz(e))},_.utils.colourNameToHex=function(e){var t={Yellow:"#ffff00",Red:"#ff0000",White:"#ffffff",Green:"#008000",Blue:"#0000ff",Lime:"#00ff00",Fuchsia:"#ff00ff",Black:"#000000"};return void 0!==t[e]?t[e]:"#ffff00"},(_=_||{}).env=_.env||{},_.env.askModernizr=function(e){void 0===_.Modernizr&&_.ModernizrInit(l,document);for(var t=e.split("."),n=_.Modernizr,i=0;i<t.length;++i)n=n[t[i]];return n},_.env.hasFileApi=function(){return-1===navigator.appVersion.indexOf("Safari")||-1!==navigator.appVersion.indexOf("Chrome")||-1===navigator.appVersion.indexOf("5.0.")&&-1===navigator.appVersion.indexOf("5.1.")?_.env.askModernizr("filereader"):(_.logger.warn("Assuming FileAPI support for Safari5..."),!0)},_.env.hasXmlHttpRequest=function(){return _.env.askModernizr("xhrresponsetype")&&_.env.askModernizr("xhrresponsetypearraybuffer")&&_.env.askModernizr("xhrresponsetypetext")&&"XMLHttpRequest"in l&&"withCredentials"in new XMLHttpRequest},_.env.hasTypedArray=function(){return _.env.askModernizr("dataview")&&_.env.askModernizr("typedarrays")},_.env.hasInputColor=function(){return _.env.askModernizr("inputtypes.color")},_.env.hasInputDirectory=function(){return _.env.askModernizr("fileinputdirectory")},_.env._hasTypedArraySlice=void 0!==Uint8Array.prototype.slice,_.env.hasTypedArraySlice=function(){return _.env._hasTypedArraySlice},_.env._hasFloat64Array="Float64Array"in l,_.env.hasFloat64Array=function(){return _.env._hasFloat64Array},_.env._hasClampedArray="Uint8ClampedArray"in l,_.env.hasClampedArray=function(){return _.env._hasClampedArray},_.env._hasBigint="undefined"!=typeof BigInt,_.env.hasBigInt=function(){return _.env._hasBigint},_.env._hasTextDecoder="undefined"!=typeof TextDecoder,_.env.hasTextDecoder=function(){return _.env._hasTextDecoder},_.env._hasTextEncoder="undefined"!=typeof TextEncoder,_.env.hasTextEncoder=function(){return _.env._hasTextEncoder},_.env.check=function(){var e="";if(!_.env.hasFileApi())throw e="The File APIs are not supported in this browser. ",new Error(e);if(!_.env.hasXmlHttpRequest())throw e="The XMLHttpRequest is not supported in this browser. ",new Error(e);if(!_.env.hasTypedArray())throw e="The Typed arrays are not supported in this browser. ",new Error(e);if(!_.env.hasTextDecoder()||!_.env.hasTextEncoder())throw e="Text decoding/encoding is not supported in this browser.",new Error(e);_.env.hasFloat64Array()||_.logger.warn("Float64Array is not supported in this browser. Data including tags with Float64 VR is not supported. "),_.env.hasBigInt()||_.logger.warn("BigInt is not supported in this browser. Data including tags with Int64 and Uint64 VRs is not supported. "),_.env.hasTypedArraySlice()||(_.logger.warn("The TypedArray.slice method is not supported in this browser. This may impair performance. "),Uint16Array.prototype.slice=function(e,t){for(var n=t-e,i=new Uint16Array(n),r=0;r<n;r++)i[r]=this[e+r];return i},Int16Array.prototype.slice=function(e,t){for(var n=t-e,i=new Int16Array(n),r=0;r<n;r++)i[r]=this[e+r];return i},Uint8Array.prototype.slice=function(e,t){for(var n=t-e,i=new Uint8Array(n),r=0;r<n;r++)i[r]=this[e+r];return i},Int8Array.prototype.slice=function(e,t){for(var n=t-e,i=new Int8Array(n),r=0;r<n;r++)i[r]=this[e+r];return i}),_.env.hasClampedArray()||(_.logger.warn("The Uint8ClampedArray is not supported in this browser. This may impair performance. "),l.Uint8ClampedArray=l.Uint8Array),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(e){if(null===this)throw new TypeError('"this" is null or not defined');var t=Object(this),n=t.length>>>0;if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var i=arguments[1],r=0;r<n;){var o=t[r];if(e.call(i,o,r,t))return o;r++}},configurable:!0,writable:!0}),String.prototype.startsWith||Object.defineProperty(String.prototype,"startsWith",{value:function(e,t){return _.utils.startsWith(this,e,t)}})},(_=_||{}).i18n=function(e,t){e=e.split(".");if(2!==e.length)throw new Error("Unexpected translation key length.");if("unit"!==e[0])throw new Error("Unexpected translation key prefix.");return{mm:"mm",cm2:"cm²",degree:"°"}[e[1]]},(_=_||{}).utils=_.utils||{},_.utils.ListenerHandler=function(){var i={};this.add=function(e,t){void 0===i[e]&&(i[e]=[]),i[e].push(t)},this.remove=function(e,t){if(void 0!==i[e])for(var n=0;n<i[e].length;++n)i[e][n]===t&&i[e].splice(n,1)},this.fireEvent=function(e){if(void 0!==i[e.type])for(var t=i[e.type].slice(),n=0;n<t.length;++n)t[n](e)}},(_=_||{}).utils=_.utils||{},_.utils.logger=_.utils.logger||{},_.utils.logger.console=_.utils.logger.console||{},_.logger=_.utils.logger.console,_.utils.logger.levels={TRACE:0,DEBUG:1,INFO:2,WARN:3,ERROR:4},_.utils.logger.console.level=_.utils.logger.levels.WARN,_.utils.logger.console.trace=function(e){_.logger.level<=_.utils.logger.levels.TRACE&&console.trace(e)},_.utils.logger.console.debug=function(e){_.logger.level<=_.utils.logger.levels.DEBUG&&console.debug(e)},_.utils.logger.console.info=function(e){_.logger.level<=_.utils.logger.levels.INFO&&console.info(e)},_.utils.logger.console.warn=function(e){_.logger.level<=_.utils.logger.levels.WARN&&console.warn(e)},_.utils.logger.console.error=function(e){_.logger.level<=_.utils.logger.levels.ERROR&&console.error(e)},(_=_||{}).ModernizrInit=function(e,a,s){var i=[],t={_version:"3.6.0",_config:{classPrefix:"",enableClasses:!0,enableJSClass:!0,usePrefixes:!0},_q:[],on:function(e,t){var n=this;setTimeout(function(){t(n[e])},0)},addTest:function(e,t,n){i.push({name:e,fn:t,options:n})},addAsyncTest:function(e){i.push({name:null,fn:e})}},n=function(){},r=(n.prototype=t,(n=new n).addTest("dataview","undefined"!=typeof DataView&&"getFloat64"in DataView.prototype),n.addTest("typedarrays","ArrayBuffer"in e),n.addTest("filereader",!!(e.File&&e.FileList&&e.FileReader)),n.addTest("xhrresponsetype",function(){if("undefined"==typeof XMLHttpRequest)return!1;var e=new XMLHttpRequest;return e.open("get","/",!0),"response"in e}()),n.addTest("urlparser",function(){try{return"http://modernizr.com/"===new URL("http://modernizr.com/").href}catch(e){return!1}}),n.addTest("urlsearchparams","URLSearchParams"in e),[]);function o(e){if("undefined"==typeof XMLHttpRequest)return!1;var t=new XMLHttpRequest;t.open("get","/",!0);try{t.responseType=e}catch(e){return!1}return"response"in t&&t.responseType==e}var u=a.documentElement,l=(n.addTest("xhrresponsetypearraybuffer",o("arraybuffer")),n.addTest("xhrresponsetypejson",o("json")),n.addTest("xhrresponsetypetext",o("text")),"svg"===u.nodeName.toLowerCase());function c(e){return"function"!=typeof a.createElement?a.createElement(e):l?a.createElementNS.call(a,"http://www.w3.org/2000/svg",e):a.createElement.apply(a,arguments)}var d,g,x,S,m,h,f,p=c("input"),e="search tel url email datetime date month week time datetime-local number range color".split(" "),y={},D=(n.inputtypes=function(e){for(var t,n,i,r=e.length,o=0;o<r;o++)p.setAttribute("type",t=e[o]),(i="text"!==p.type&&"style"in p)&&(p.value="1)",p.style.cssText="position:absolute;visibility:hidden;",/^range$/.test(t)&&p.style.WebkitAppearance!==s?(u.appendChild(p),i=(n=a.defaultView).getComputedStyle&&"textfield"!==n.getComputedStyle(p,null).WebkitAppearance&&0!==p.offsetHeight,u.removeChild(p)):/^(search|tel)$/.test(t)||(i=/^(url|email)$/.test(t)?p.checkValidity&&!1===p.checkValidity():"1)"!=p.value)),y[e[o]]=!!i;return y}(e),t._config.usePrefixes?"Moz O ms Webkit".toLowerCase().split(" "):[]);for(f in t._domPrefixes=D,n.addTest("fileinputdirectory",function(){var e=c("input");if(e.type="file","directory"in e)return!0;for(var t=0,n=D.length;t<n;t++)if(D[t]+"directory"in e)return!0;return!1}),i)if(i.hasOwnProperty(f)){if(d=[],(g=i[f]).name&&(d.push(g.name.toLowerCase()),g.options&&g.options.aliases&&g.options.aliases.length))for(x=0;x<g.options.aliases.length;x++)d.push(g.options.aliases[x].toLowerCase());for(S="function"==typeof g.fn?g.fn():g.fn,m=0;m<d.length;m++)1===(h=d[m].split(".")).length?n[h[0]]=S:(!n[h[0]]||n[h[0]]instanceof Boolean||(n[h[0]]=new Boolean(n[h[0]])),n[h[0]][h[1]]=S),r.push((S?"":"no-")+h.join("-"))}delete t.addTest,delete t.addAsyncTest;for(var v=0;v<n._q.length;v++)n._q[v]();_.Modernizr=n},(_=_||{}).utils=_.utils||{},_.utils.isObject=function(e){var t=typeof e;return"function"==t||"object"==t&&!!e},_.utils.isArray=function(e){return Array.isArray(e)},_.utils.objectToArray=function(e){for(var t=[],n=Object.keys(e),i=0;i<n.length;++i){for(var r=n[i],o={name:r},a=Object.keys(e[r]),s=0;s<a.length;++s){var u=a[s],l=e[r][u];if(_.utils.isArray(l)){for(var c=[],d=0;d<l.length;++d)_.utils.isObject(l[d])?c.push(_.utils.objectToArray(l[d])):c.push(l[d]);l=c}else _.utils.isObject(l)&&(l=_.utils.objectToArray(l));o[u]=l}t.push(o)}return t},_.utils.mergeObjects=function(e,t,n,i){var r={};if(!n)throw new Error("Cannot merge object with an undefined id key: "+n);if(!Object.prototype.hasOwnProperty.call(e,n))throw new Error("Id key not found in first object while merging: "+n+", obj: "+e);if(!Object.prototype.hasOwnProperty.call(t,n))throw new Error("Id key not found in second object while merging: "+n+", obj: "+t);if(!i)throw new Error("Cannot merge object with an undefined value key: "+i);var o=!1;if(Object.prototype.hasOwnProperty.call(e[n],"merged")&&e[n].merged&&(o=!0),!Object.prototype.hasOwnProperty.call(e[n],i))throw new Error("Id value not found in first object while merging: "+n+", valueKey: "+i+", ojb: "+e);if(!Object.prototype.hasOwnProperty.call(t[n],i))throw new Error("Id value not found in second object while merging: "+n+", valueKey: "+i+", ojb: "+t);var a=e[n][i],s=t[n][i];if(o){for(var u=0;u<a.length;++u)if(a[u]===s)throw new Error("The first object already contains id2: "+s+", id1: "+a);r[n]=e[n],r[n][i].push(s)}else{if(a===s)throw new Error("Cannot merge object with same ids: "+a+", id2: "+s);r[n]={value:[a,s],merged:!0}}for(var l=Object.keys(e),c=Object.keys(t).filter(function(e){return l.indexOf(e)<0}),d=l.concat(c),g=0,x=d.length;g<x;++g){var S=d[g];if(S!==n){var m,h=null,f=null,p=(Object.prototype.hasOwnProperty.call(e,S)&&(h=e[S],Object.prototype.hasOwnProperty.call(h,i)&&(f=h[i])),null),y=null;if(Object.prototype.hasOwnProperty.call(t,S)&&(p=t[S],Object.prototype.hasOwnProperty.call(p,i)&&(y=p[i])),y!==f)if(m={},o){if(_.utils.isObject(f))m[i]=f;else{m[i]={};for(var D=0;D<a.length;D++)m[i][a[D]]=h}m[i][s]=p}else{y={};y[a]=h,y[s]=p,m[i]=y}else m=h;r[S]=m}}return r},(_=_||{}).utils=_.utils||{},_.utils.MultiProgressHandler=function(n){var i=this,r=[],o=2;function a(e){for(var t=0,n=0;n<o;++n)t+=r[e][n];return t/o}this.setNumberOfDimensions=function(e){o=e},this.setNToLoad=function(e){for(var t=0;t<e;++t){r[t]=[];for(var n=0;n<o;++n)r[t][n]=0}},this.onprogress=function(e){var t;e.lengthComputable&&void 0!==e.subindex&&void 0!==e.index&&(t=100*e.loaded/e.total,r[e.index][e.subindex]=t,t=null,t=void 0!==e.item?e.item:{loaded:a(e.index),total:100,source:e.source},n({lengthComputable:!0,loaded:function(){for(var e=0,t=r.length,n=0;n<t;++n)e+=a(n);return Math.round(e/t)}(),total:100,item:t}))},this.getMonoProgressHandler=function(t,n){return function(e){e.index=t,e.subindex=n,i.onprogress(e)}},this.getUndefinedMonoProgressHandler=function(t){return function(e){e.subindex=t,i.onprogress(e)}}},(_=_||{}).utils=_.utils||{},_.utils.capitaliseFirstLetter=function(e){var t=e;return t=e?e.charAt(0).toUpperCase()+e.slice(1):t},_.utils.startsWith=function(e,t,n){if(null==e||null==t)return!1;n=0<n?0|n:0;return e.substring(n,n+t.length)===t},_.utils.endsWith=function(e,t){return null!=e&&null!=t&&e.substring(e.length-t.length)===t},_.utils.splitKeyValueString=function(e){var t={};if(e)for(var n=e.split("&"),i=0;i<n.length;++i){var r=n[i].split("=");t[r[0]]?(t[r[0]]instanceof Array||(t[r[0]]=[t[r[0]]]),t[r[0]].push(r[1])):t[r[0]]=r[1]}return t},_.utils.getFlags=function(e){var t=[];if(null==e)return t;for(var n=/{(\w+)}/g,i=n.exec(e);i;)t.push(i[1]),i=n.exec(e);return t},_.utils.replaceFlags=function(e,t){var n="";if(null==e)return n;if(n=e,null==t)return n;for(var i=_.utils.getFlags(e),r=0;r<i.length;++r){var o,a=t[i[r]];null!=a&&null!==a.value&&void 0!==a.value&&(o=a.value.toPrecision(4),null!==a.unit&&void 0!==a.unit&&0!==a.unit.length&&("degree"!==a.unit&&(o+=" "),o+=a.unit),a="{"+i[r]+"}",n=n.replace(a,o))}return n},_.utils.replaceFlags2=function(e,t){for(var n=e,i=0;i<t.length;++i)n=n.replace("{v"+i+"}",t[i]);return n},_.utils.createDefaultReplaceFormat=function(e){for(var t="",n=0;n<e.length;++n)0!==n&&(t+=", "),t+="{v"+n+"}";return t},_.utils.getRootPath=function(e){return e.split("/").slice(0,-1).join("/")},_.utils.getFileExtension=function(e){var t=null;return null!=e&&"."!==e[0]&&1!==(e=e.toLowerCase().split(".")).length&&(t=e.pop(),/[a-z]/.test(t)&&!t.includes("/")||(t=null)),t},_.utils.stringToUint8Array=function(e){for(var t=new Uint8Array(e.length),n=0,i=e.length;n<i;n++)t[n]=e.charCodeAt(n);return t},_.utils.precisionRound=function(e,t){t=Math.pow(10,t);return Math.round(e*t+.01/t)/t},(_=_||{}).utils=_.utils||{},_.utils.ThreadPool=function(i){for(var r=[],o=[],e=0;e<i;++e)o.push(new _.utils.WorkerThread(this));var a=[];function t(){r=[];for(var e=0;e<a.length;++e)a[e].stop();a=[]}this.addWorkerTask=function(e){var t;o.length===i&&this.onworkstart({type:"work-start"}),0<o.length?(t=o.shift(),a.push(t),t.run(e)):r.push(e)},this.abort=function(){t(),this.onabort({type:"work-abort"}),this.onworkend({type:"work-end"})},this.onTaskEnd=function(e){if(0<r.length){var t=r.shift();e.run(t)}else{e.stop(),o.push(e);for(var n=0;n<a.length;++n)a[n].getId()===e.getId()&&a.splice(n,1);o.length===i&&(this.onwork({type:"work"}),this.onworkend({type:"work-end"}))}},this.handleWorkerError=function(e){t(),this.onerror({error:e}),this.onworkend({type:"work-end"})}},_.utils.ThreadPool.prototype.onworkstart=function(e){},_.utils.ThreadPool.prototype.onworkitem=function(e){},_.utils.ThreadPool.prototype.onwork=function(e){},_.utils.ThreadPool.prototype.onworkend=function(e){},_.utils.ThreadPool.prototype.onerror=function(e){},_.utils.ThreadPool.prototype.onabort=function(e){},_.utils.WorkerThread=function(t){var n,i=this,e=Math.random().toString(36).substring(2,15),r=null;function o(e){e.itemNumber=r.info.itemNumber,e.numberOfItems=r.info.numberOfItems,e.dataIndex=r.info.dataIndex,t.onworkitem(e),t.onTaskEnd(i)}function a(e){e.itemNumber=r.info.itemNumber,e.numberOfItems=r.info.numberOfItems,e.dataIndex=r.info.dataIndex,t.handleWorkerError(e),i.stop()}this.getId=function(){return e},this.run=function(e){r=e,void 0===n&&((n=new Worker(r.script)).onmessage=o,n.onerror=a),n.postMessage(r.startMessage)},this.stop=function(){n.terminate()}},_.utils.WorkerTask=function(e,t,n){this.script=e,this.startMessage=t,this.info=n},(_=_||{}).utils=_.utils||{},_.utils.getUrlFromUriFull=function(e){return new URL(e,l.location.origin)},_.utils.getUrlFromUriSimple=function(e){for(var t={},e=e.split("?"),n=e[0].split("//").pop().split("/"),i=(n.splice(0,1),t.pathname="/"+n.join("/"),[]),r=(2===e.length&&(i=e[1].split("&")),{}),o=0;o<i.length;++o){var a=i[o].split("=");r[a[0]]=a[1]}return t.searchParams={get:function(e){return r[e]}},t},_.utils.getUrlFromUri=function(e){return _.env.askModernizr("urlparser")&&_.env.askModernizr("urlsearchparams")?_.utils.getUrlFromUriFull(e):_.utils.getUrlFromUriSimple(e)},_.utils.splitUri=function(e){var t,n={},i=null;return e&&-1!==(i=e.indexOf("?"))&&(n.base=e.substring(0,i),-1===(t=e.indexOf("#"))&&(t=e.length),e=e.substring(i+1,t),n.query=_.utils.splitKeyValueString(e)),n},_.utils.getUriQuery=function(e){e=_.utils.splitUri(e);return 0===Object.keys(e).length?null:e.query},_.utils.decodeQuery=function(e,t,n){e.type&&"manifest"===e.type?_.utils.decodeManifestQuery(e,t):t(_.utils.decodeKeyValueUri(e.input,e.dwvReplaceMode),n)},_.utils.decodeKeyValueUri=function(e,t){var n=[],i="key",t=(t&&(i=t),decodeURIComponent(e)),r=_.utils.splitUri(t);if(0===Object.keys(r).length)n.push(t);else{for(var o=Object.keys(r.query),a=null,s=0;s<o.length;++s)if(r.query[o[s]]instanceof Array){a=o[s];break}if(a){for(var u,l=r.query[a],c=r.base,d=(""!==c&&"file"!==a&&(c+="?"),!1),g=0;g<o.length;++g)o[g]!==a&&(d&&(c+="&"),c+=o[g]+"="+r.query[o[g]],d=!0);for(var x=0;x<l.length;++x)u=c,d&&(u+="&"),"key"===i&&(u+=a+"="),u+=l[x],n.push(u)}else n.push(t)}return n},_.utils.decodeManifestQuery=function(e,t){var n="",i=("/"===e.input[0]&&(n=l.location.protocol+"//"+l.location.host),n+=e.input,new XMLHttpRequest);i.open("GET",decodeURIComponent(n),!0),i.responseType="document",i.onload=function(){t(_.utils.decodeManifest(this.responseXML,e.nslices))},i.onerror=function(){_.logger.warn("RequestError while receiving manifest: "+this.status)},i.send(null)},_.utils.decodeManifest=function(e,t){var n=[],i=e.getElementsByTagName("wado_query")[0].getAttribute("wadoURL")+"?requestType=WADO&contentType=application/dicom&",e=e.getElementsByTagName("Patient"),e=(1<e.length&&_.logger.warn("More than one patient, loading first one."),e[0].getElementsByTagName("Study")),r=(1<e.length&&_.logger.warn("More than one study, loading first one."),e[0].getAttribute("StudyInstanceUID")),e=e[0].getElementsByTagName("Series"),o=(1<e.length&&_.logger.warn("More than one series, loading first one."),e[0].getAttribute("SeriesInstanceUID")),a=e[0].getElementsByTagName("Instance"),s=a.length;t<s&&(s=t);for(var u=0;u<s;++u){var l=a[u].getAttribute("SOPInstanceUID");n.push(i+"&studyUID="+r+"&seriesUID="+o+"&objectUID="+l)}return n},_.utils.loadFromUri=function(e,t,n){e=_.utils.getUriQuery(e);e&&void 0!==e.input&&_.utils.loadFromQuery(e,t,n)},_.utils.loadFromQuery=function(e,t,n){var i;_.utils.decodeQuery(e,t.loadURLs,n),void 0!==e.state&&t.addEventListener("loadend",i=function(){t.removeEventListener("loadend",i),t.loadURLs([e.state])})},_});
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("konva"),require("jszip"),require("magic-wand-tool")):"function"==typeof define&&define.amd?define(["konva","jszip","konmagic-wand-tool"],t):"object"==typeof exports?exports.dwv=t(require("konva"),require("jszip"),require("magic-wand-tool")):e.dwv=t(e.Konva,e.JSZip,e.MagicWand)}(this,(function(e,t,n){return function(){"use strict";var i={626:function(e){e.exports=t},436:function(t){t.exports=e},812:function(e){e.exports=n}},r={};function a(e){var t=r[e];if(void 0!==t)return t.exports;var n=r[e]={exports:{}};return i[e](n,n.exports,a),n.exports}a.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(t,{a:t}),t},a.d=function(e,t){for(var n in t)a.o(t,n)&&!a.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},a.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var o={};return function(){function e(e,n){return function(e,t){return t.get?t.get.call(e):t.value}(e,t(e,n,"get"))}function t(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}a.r(o),a.d(o,{App:function(){return Qy},DicomParser:function(){return un},DicomWriter:function(){return Tv},DrawLayer:function(){return Yo},Geometry:function(){return Gn},Image:function(){return Di},Index:function(){return i},LayerGroup:function(){return Ts},Matrix33:function(){return Ie},Point:function(){return Ne},Point3D:function(){return ke},Size:function(){return Ln},Spacing:function(){return On},Tag:function(){return Je},TagValueExtractor:function(){return ic},Vector3D:function(){return pe},ViewLayer:function(){return va},buildMultipart:function(){return Ft},customUI:function(){return Er},decoderScripts:function(){return su},defaultPresets:function(){return O},dictionary:function(){return We},getDwvVersion:function(){return Bt},getElementsFromJSONTags:function(){return Mv},getOrientationName:function(){return Wt},getPixelDataTag:function(){return at},getTypedArray:function(){return Yt},getUID:function(){return rv},getUriQuery:function(){return ec},isArray:function(){return Vd},isObject:function(){return Wd},loadFromUri:function(){return tc},logger:function(){return re},lut:function(){return ie},objectToArray:function(){return Gd},precisionRound:function(){return Lt}});var n=new WeakMap;class i{constructor(e){if(a={writable:!0,value:void 0},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(i=this,r=n),r.set(i,a),!e||void 0===e)throw new Error("Cannot create index with no values.");var i,r,a;if(0===e.length)throw new Error("Cannot create index with empty values.");if(!e.every((function(e){return!isNaN(e)})))throw new Error("Cannot create index with non number values.");!function(e,n,i){(function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}})(e,t(e,n,"set"),i)}(this,n,e)}get(t){return e(this,n)[t]}length(){return e(this,n).length}toString(){return"("+e(this,n).toString()+")"}getValues(){return e(this,n).slice()}canCompare(e){return!!e&&this.length()===e.length()}equals(e){if(!this.canCompare(e))return!1;for(let t=0,n=this.length();t<n;++t)if(this.get(t)!==e.get(t))return!1;return!0}compare(e){if(!this.canCompare(e))return null;const t=[];for(let n=0,i=this.length();n<i;++n)this.get(n)!==e.get(n)&&t.push(n);return t}add(e){if(!this.canCompare(e))return null;const t=[];for(let n=0,i=this.length();n<i;++n)t.push(this.get(n)+e.get(n));return new i(t)}getWithNew2D(e,t){const n=[e,t];for(let e=2,t=this.length();e<t;++e)n.push(this.get(e));return new i(n)}toStringId(e){if(void 0===e){e=[];for(let t=0;t<this.length();++t)e.push(t)}for(let t=0;t<e.length;++t)if(e[t]>=this.length())throw new Error("Non valid dimension for toStringId.");let t="";for(let n=0;n<e.length;++n)0!==n&&(t+="_"),t+="#"+e[n]+"-"+this.get(e[n]);return t}}function r(e){const t=e.split("_");let n,r=0;for(let e=0;e<t.length;++e)n=parseInt(t[e].substring(1,2),10),n>r&&(r=n);if(0===r)throw new Error("No dimension found in point stringId");const a=new Array(r);a.fill(0);for(let e=0;e<t.length;++e){n=parseInt(t[e].substring(1,3),10);const i=parseInt(t[e].substring(3),10);a[n]=i}return new i(a)}function s(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function l(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,u(e,t,"get"))}function c(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,u(e,t,"set"),n),n}function u(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var h=new WeakMap,d=new WeakMap;class S{constructor(e,t){s(this,h,{writable:!0,value:void 0}),s(this,d,{writable:!0,value:void 0}),c(this,h,e),c(this,d,t)}getSlope(){return l(this,h)}getIntercept(){return l(this,d)}apply(e){return e*l(this,h)+l(this,d)}equals(e){return null!==e&&this.getSlope()===e.getSlope()&&this.getIntercept()===e.getIntercept()}toString(){return this.getSlope()+", "+this.getIntercept()}isID(){return 1===this.getSlope()&&0===this.getIntercept()}}function g(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function p(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,m(e,t,"get"))}function f(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,m(e,t,"set"),n),n}function m(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var y=new WeakMap,v=new WeakMap,D=new WeakMap,w=new WeakMap;class C{constructor(e,t){g(this,y,{writable:!0,value:void 0}),g(this,v,{writable:!0,value:null}),g(this,D,{writable:!0,value:!1}),g(this,w,{writable:!0,value:void 0}),f(this,y,e),f(this,w,Math.pow(2,t))}getRSI(){return p(this,y)}isReady(){return p(this,D)}initialise(){if(!p(this,D)){f(this,v,new Float32Array(p(this,w)));for(let e=0;e<p(this,w);++e)p(this,v)[e]=p(this,y).apply(e);f(this,D,!0)}}getLength(){return p(this,w)}getValue(e){return p(this,v)[e]}}function T(e,t,n){I(e,t),t.set(e,n)}function I(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function L(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,A(e,t,"get"))}function b(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function P(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,A(e,t,"set"),n),n}function A(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}const O={CT:{mediastinum:{center:40,width:400},lung:{center:-500,width:1500},bone:{center:500,width:2e3},brain:{center:40,width:80},head:{center:90,width:350}}};var x=new WeakMap,F=new WeakMap,R=new WeakMap,E=new WeakMap,M=new WeakMap,q=new WeakMap,U=new WeakMap,Q=new WeakMap,k=new WeakMap,B=new WeakSet;class N{constructor(e,t){var n;if(I(this,n=B),n.add(this),T(this,x,{writable:!0,value:void 0}),T(this,F,{writable:!0,value:void 0}),T(this,R,{writable:!0,value:0}),T(this,E,{writable:!0,value:0}),T(this,M,{writable:!0,value:255}),T(this,q,{writable:!0,value:null}),T(this,U,{writable:!0,value:null}),T(this,Q,{writable:!0,value:null}),T(this,k,{writable:!0,value:null}),t<1)throw new Error("Window width shall always be greater than or equal to 1");P(this,x,e),P(this,F,t),b(this,B,W).call(this)}getCenter(){return L(this,x)}getWidth(){return L(this,F)}setRange(e,t){P(this,E,parseInt(e,10)),P(this,M,parseInt(t,10)),b(this,B,W).call(this)}setSignedOffset(e){P(this,R,e),b(this,B,W).call(this)}apply(e){return e<=L(this,q)?L(this,E):e>L(this,U)?L(this,M):e*L(this,Q)+L(this,k)}equals(e){return null!==e&&this.getCenter()===e.getCenter()&&this.getWidth()===e.getWidth()}toString(){return this.getCenter()+", "+this.getWidth()}}function W(){const e=L(this,x)+L(this,R);P(this,q,e-.5-(L(this,F)-1)/2),P(this,U,e-.5+(L(this,F)-1)/2),P(this,Q,(L(this,M)-L(this,E))/(L(this,F)-1)),P(this,k,(-(e-.5)/(L(this,F)-1)+.5)*(L(this,M)-L(this,E))+L(this,E))}function V(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function G(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,H(e,t,"get"))}function z(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,H(e,t,"set"),n),n}function H(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var j=new WeakMap,X=new WeakMap,Y=new WeakMap,_=new WeakMap,Z=new WeakMap,K=new WeakMap;class J{constructor(e,t){V(this,j,{writable:!0,value:void 0}),V(this,X,{writable:!0,value:void 0}),V(this,Y,{writable:!0,value:null}),V(this,_,{writable:!0,value:null}),V(this,Z,{writable:!0,value:!1}),V(this,K,{writable:!0,value:0}),z(this,j,e),z(this,X,t)}getWindowLevel(){return G(this,_)}isSigned(){return G(this,X)}getRescaleLut(){return G(this,j)}isReady(){return G(this,Z)}setWindowLevel(e){if(z(this,_,e),z(this,K,0),G(this,_).setSignedOffset(0),G(this,X)){const e=G(this,j).getLength();z(this,K,e/2),G(this,_).setSignedOffset(G(this,j).getRSI().getSlope()*G(this,K))}z(this,Z,!1)}update(){if(G(this,Z))return;G(this,j).isReady()||G(this,j).initialise();const e=G(this,j).getLength();G(this,Y)||z(this,Y,new Uint8ClampedArray(e));for(let t=0;t<e;++t)G(this,Y)[t]=G(this,_).apply(G(this,j).getValue(t));z(this,Z,!0)}getLength(){return G(this,Y).length}getValue(e){return G(this,Y)[e+G(this,K)]}}const $=256;function ee(e){const t=[];for(let n=0;n<$;++n)t.push(e(n));return t}function te(e){return e}function ne(e){return 255-e}const ie={plain:{red:ee(te),green:ee(te),blue:ee(te)},invPlain:{red:ee(ne),green:ee(ne),blue:ee(ne)},rainbow:{blue:[0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224,228,232,236,240,244,248,252,255,247,239,231,223,215,207,199,191,183,175,167,159,151,143,135,127,119,111,103,95,87,79,71,63,55,47,39,31,23,15,7,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,16,24,32,40,48,56,64,72,80,88,96,104,112,120,128,136,144,152,160,168,176,184,192,200,208,216,224,232,240,248,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,253,251,249,247,245,243,241,239,237,235,233,231,229,227,225,223,221,219,217,215,213,211,209,207,205,203,201,199,197,195,193,192,189,186,183,180,177,174,171,168,165,162,159,156,153,150,147,144,141,138,135,132,129,126,123,120,117,114,111,108,105,102,99,96,93,90,87,84,81,78,75,72,69,66,63,60,57,54,51,48,45,42,39,36,33,30,27,24,21,18,15,12,9,6,3],red:[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,62,60,58,56,54,52,50,48,46,44,42,40,38,36,34,32,30,28,26,24,22,20,18,16,14,12,10,8,6,4,2,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224,228,232,236,240,244,248,252,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255]},hot:{red:ee((function(e){const t=3*e;return t>255?255:t})),green:ee((function(e){const t=$/3;let n=0;return e>=t&&(n=3*(e-t),n>255)?255:n})),blue:ee((function(e){const t=$/3;let n=0;return e>=2*t&&(n=3*(e-2*t),n>255)?255:n}))},hot_iron:{red:[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,172,174,176,178,180,182,184,186,188,190,192,194,196,198,200,202,204,206,208,210,212,214,216,218,220,222,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,254,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,172,174,176,178,180,182,184,186,188,190,192,194,196,198,200,202,204,206,208,210,212,214,216,218,220,222,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,255],blue:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,84,88,92,96,100,104,108,112,116,120,124,128,132,136,140,144,148,152,156,160,164,168,172,176,180,184,188,192,196,200,204,208,212,216,220,224,228,232,236,240,244,248,252,255]},pet:{red:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,171,173,175,177,179,181,183,185,187,189,191,193,195,197,199,201,203,205,207,209,211,213,215,217,219,221,223,225,227,229,231,233,235,237,239,241,243,245,247,249,251,253,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97,99,101,103,105,107,109,111,113,115,117,119,121,123,125,128,126,124,122,120,118,116,114,112,110,108,106,104,102,100,98,96,94,92,90,88,86,84,82,80,78,76,74,72,70,68,66,64,63,61,59,57,55,53,51,49,47,45,43,41,39,37,35,33,31,29,27,25,23,21,19,17,15,13,11,9,7,5,3,1,0,2,4,6,8,10,12,14,16,18,20,22,24,26,28,30,32,34,36,38,40,42,44,46,48,50,52,54,56,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,118,120,122,124,126,128,130,132,134,136,138,140,142,144,146,148,150,152,154,156,158,160,162,164,166,168,170,172,174,176,178,180,182,184,186,188,190,192,194,196,198,200,202,204,206,208,210,212,214,216,218,220,222,224,226,228,230,232,234,236,238,240,242,244,246,248,250,252,255],blue:[0,1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,85,87,89,91,93,95,97,99,101,103,105,107,109,111,113,115,117,119,121,123,125,127,129,131,133,135,137,139,141,143,145,147,149,151,153,155,157,159,161,163,165,167,169,171,173,175,177,179,181,183,185,187,189,191,193,195,197,199,201,203,205,207,209,211,213,215,217,219,221,223,225,227,229,231,233,235,237,239,241,243,245,247,249,251,253,255,252,248,244,240,236,232,228,224,220,216,212,208,204,200,196,192,188,184,180,176,172,168,164,160,156,152,148,144,140,136,132,128,124,120,116,112,108,104,100,96,92,88,84,80,76,72,68,64,60,56,52,48,44,40,36,32,28,24,20,16,12,8,4,0,4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76,80,85,89,93,97,101,105,109,113,117,121,125,129,133,137,141,145,149,153,157,161,165,170,174,178,182,186,190,194,198,202,206,210,214,218,222,226,230,234,238,242,246,250,255]},hot_metal_blue:{red:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,6,9,12,15,18,21,24,26,29,32,35,38,41,44,47,50,52,55,57,59,62,64,66,69,71,74,76,78,81,83,85,88,90,93,96,99,102,105,108,111,114,116,119,122,125,128,131,134,137,140,143,146,149,152,155,158,161,164,166,169,172,175,178,181,184,187,190,194,198,201,205,209,213,217,221,224,228,232,236,240,244,247,251,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,4,6,8,9,11,13,15,17,19,21,23,24,26,28,30,32,34,36,38,40,41,43,45,47,49,51,53,55,56,58,60,62,64,66,68,70,72,73,75,77,79,81,83,85,87,88,90,92,94,96,98,100,102,104,105,107,109,111,113,115,117,119,120,122,124,126,128,130,132,134,136,137,139,141,143,145,147,149,151,152,154,156,158,160,162,164,166,168,169,171,173,175,177,179,181,183,184,186,188,190,192,194,196,198,200,201,203,205,207,209,211,213,215,216,218,220,222,224,226,228,229,231,233,235,237,239,240,242,244,246,248,250,251,253,255],blue:[0,2,4,6,8,10,12,14,16,17,19,21,23,25,27,29,31,33,35,37,39,41,43,45,47,49,51,53,55,57,59,61,63,65,67,69,71,73,75,77,79,81,83,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,117,119,121,123,125,127,129,131,133,135,137,139,141,143,145,147,149,151,153,155,157,159,161,163,165,167,169,171,173,175,177,179,181,183,184,186,188,190,192,194,196,198,200,197,194,191,188,185,182,179,176,174,171,168,165,162,159,156,153,150,144,138,132,126,121,115,109,103,97,91,85,79,74,68,62,56,50,47,44,41,38,35,32,29,26,24,21,18,15,12,9,6,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,3,6,9,12,15,18,21,24,26,29,32,35,38,41,44,47,50,53,56,59,62,65,68,71,74,76,79,82,85,88,91,94,97,100,103,106,109,112,115,118,121,124,126,129,132,135,138,141,144,147,150,153,156,159,162,165,168,171,174,176,179,182,185,188,191,194,197,200,203,206,210,213,216,219,223,226,229,232,236,239,242,245,249,252,255]},pet_20step:{red:[0,0,0,0,0,0,0,0,0,0,0,0,0,96,96,96,96,96,96,96,96,96,96,96,96,96,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,96,96,96,96,96,96,96,96,96,96,96,96,96,112,112,112,112,112,112,112,112,112,112,112,112,112,128,128,128,128,128,128,128,128,128,128,128,128,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,64,64,64,64,64,64,64,64,64,64,64,64,224,224,224,224,224,224,224,224,224,224,224,224,224,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,208,192,192,192,192,192,192,192,192,192,192,192,192,192,176,176,176,176,176,176,176,176,176,176,176,176,176,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255],green:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,96,96,96,96,96,96,96,96,96,96,96,96,96,112,112,112,112,112,112,112,112,112,112,112,112,112,128,128,128,128,128,128,128,128,128,128,128,128,96,96,96,96,96,96,96,96,96,96,96,96,96,144,144,144,144,144,144,144,144,144,144,144,144,144,192,192,192,192,192,192,192,192,192,192,192,192,192,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,224,208,208,208,208,208,208,208,208,208,208,208,208,208,176,176,176,176,176,176,176,176,176,176,176,176,176,144,144,144,144,144,144,144,144,144,144,144,144,96,96,96,96,96,96,96,96,96,96,96,96,96,48,48,48,48,48,48,48,48,48,48,48,48,48,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255],blue:[0,0,0,0,0,0,0,0,0,0,0,0,0,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,112,112,112,112,112,112,112,112,112,112,112,112,128,128,128,128,128,128,128,128,128,128,128,128,128,176,176,176,176,176,176,176,176,176,176,176,176,176,192,192,192,192,192,192,192,192,192,192,192,192,192,224,224,224,224,224,224,224,224,224,224,224,224,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,80,80,80,80,80,80,80,80,80,80,80,80,80,64,64,64,64,64,64,64,64,64,64,64,64,80,80,80,80,80,80,80,80,80,80,80,80,80,96,96,96,96,96,96,96,96,96,96,96,96,96,64,64,64,64,64,64,64,64,64,64,64,64,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255,255,255,255,255,255,255,255,255,255]}},re={levels:{TRACE:0,DEBUG:1,INFO:2,WARN:3,ERROR:4},level:3,trace:function(e){this.level<=this.levels.TRACE&&console.trace(e)},debug:function(e){this.level<=this.levels.DEBUG&&console.debug(e)},info:function(e){this.level<=this.levels.INFO&&console.info(e)},warn:function(e){this.level<=this.levels.WARN&&console.warn(e)},error:function(e){this.level<=this.levels.ERROR&&console.error(e)}};function ae(e){return function(e){return n=e,.001172549*(t={r:parseInt(n.substring(1,3),16),g:parseInt(n.substring(3,5),16),b:parseInt(n.substring(5,7),16)}).r+.002301961*t.g+447059e-9*t.b<.5;var t,n}(e)?"#fff":"#000"}const oe={x:95.0489,y:100,z:108.884};function se(e){const t={Yellow:"#ffff00",Red:"#ff0000",White:"#ffffff",Green:"#008000",Blue:"#0000ff",Lime:"#00ff00",Fuchsia:"#ff00ff",Black:"#000000"};let n="#ffff00";return void 0!==t[e]&&(n=t[e]),n}function le(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function ce(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,he(e,t,"get"))}function ue(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,he(e,t,"set"),n),n}function he(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var de=new WeakMap,Se=new WeakMap,ge=new WeakMap;class pe{constructor(e,t,n){le(this,de,{writable:!0,value:void 0}),le(this,Se,{writable:!0,value:void 0}),le(this,ge,{writable:!0,value:void 0}),ue(this,de,e),ue(this,Se,t),ue(this,ge,n)}getX(){return ce(this,de)}getY(){return ce(this,Se)}getZ(){return ce(this,ge)}equals(e){return null!==e&&this.getX()===e.getX()&&this.getY()===e.getY()&&this.getZ()===e.getZ()}toString(){return"("+this.getX()+", "+this.getY()+", "+this.getZ()+")"}norm(){return Math.sqrt(this.getX()*this.getX()+this.getY()*this.getY()+this.getZ()*this.getZ())}crossProduct(e){return new pe(this.getY()*e.getZ()-e.getY()*this.getZ(),this.getZ()*e.getX()-e.getZ()*this.getX(),this.getX()*e.getY()-e.getX()*this.getY())}dotProduct(e){return this.getX()*e.getX()+this.getY()*e.getY()+this.getZ()*e.getZ()}}function fe(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function me(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,ve(e,t,"get"))}function ye(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,ve(e,t,"set"),n),n}function ve(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}void 0===Number.EPSILON&&(Number.EPSILON=Math.pow(2,-52));const De=1e4*Number.EPSILON;function we(e,t,n){return void 0===n&&(n=Number.EPSILON),Math.abs(e-t)<n}var Ce=new WeakMap,Te=new WeakMap;class Ie{constructor(e){fe(this,Ce,{writable:!0,value:void 0}),fe(this,Te,{writable:!0,value:void 0}),ye(this,Ce,e)}get(e,t){return me(this,Ce)[3*e+t]}getInverse(){return void 0===me(this,Te)&&ye(this,Te,function(e){const t=e.get(0,0),n=e.get(0,1),i=e.get(0,2),r=e.get(1,0),a=e.get(1,1),o=e.get(1,2),s=e.get(2,0),l=e.get(2,1),c=e.get(2,2),u=a*c-o*l,h=o*s-r*c,d=r*l-a*s;let S=t*u+n*h+i*d;if(0!==S)return S=1/S,new Ie([S*u,S*(i*l-n*c),S*(n*o-i*a),S*h,S*(t*c-i*s),S*(i*r-t*o),S*d,S*(n*s-t*l),S*(t*a-n*r)]);re.warn("Cannot invert 3*3 matrix with zero determinant.")}(this)),me(this,Te)}equals(e,t){for(let n=0;n<3;++n)for(let i=0;i<3;++i)if(!we(this.get(n,i),e.get(n,i),t))return!1;return!0}toString(){let e="[";for(let t=0;t<3;++t){0!==t&&(e+=", \n ");for(let n=0;n<3;++n)0!==n&&(e+=", "),e+=this.get(t,n)}return e+="]",e}multiply(e){const t=[];for(let n=0;n<3;++n)for(let i=0;i<3;++i){let r=0;for(let t=0;t<3;++t)r+=this.get(n,t)*e.get(t,i);t.push(r)}return new Ie(t)}getAbs(){const e=[];for(let t=0;t<3;++t)for(let n=0;n<3;++n)e.push(Math.abs(this.get(t,n)));return new Ie(e)}multiplyArray3D(e){if(3!==e.length)throw new Error("Cannot multiply 3x3 matrix with non 3D array: "+e.length);const t=[];for(let n=0;n<3;++n){let i=0;for(let t=0;t<3;++t)i+=this.get(n,t)*e[t];t.push(i)}return t}multiplyVector3D(e){const t=this.multiplyArray3D([e.getX(),e.getY(),e.getZ()]);return new pe(t[0],t[1],t[2])}multiplyPoint3D(e){const t=this.multiplyArray3D([e.getX(),e.getY(),e.getZ()]);return new ke(t[0],t[1],t[2])}multiplyIndex3D(e){const t=this.multiplyArray3D(e.getValues());return new i(t)}getRowAbsMax(e){const t=[Math.abs(this.get(e,0)),Math.abs(this.get(e,1)),Math.abs(this.get(e,2))],n=Math.max.apply(null,t),i=t.indexOf(n);return{value:this.get(e,i),index:i}}getColAbsMax(e){const t=[Math.abs(this.get(0,e)),Math.abs(this.get(1,e)),Math.abs(this.get(2,e))],n=Math.max.apply(null,t),i=t.indexOf(n);return{value:this.get(i,e),index:i}}asOneAndZeros(){const e=[];for(let t=0;t<3;++t){const n=this.getRowAbsMax(t),i=n.value>0?1:-1;for(let t=0;t<3;++t)t===n.index?e.push(1*i):e.push(0)}return new Ie(e)}getThirdColMajorDirection(){return this.getColAbsMax(2).index}}function Le(){return new Ie([1,0,0,0,1,0,0,0,1])}function be(){return new Ie([1,0,0,0,0,1,0,-1,0])}function Pe(e){let t=null;return"axial"===e?t=Le():"coronal"===e?t=be():"sagittal"===e&&(t=new Ie([0,0,-1,1,0,0,0,-1,0])),t}function Ae(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Oe(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Fe(e,t,"get"))}function xe(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Fe(e,t,"set"),n),n}function Fe(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Re=new WeakMap,Ee=new WeakMap;class Me{constructor(e,t){Ae(this,Re,{writable:!0,value:void 0}),Ae(this,Ee,{writable:!0,value:void 0}),xe(this,Re,e),xe(this,Ee,t)}getX(){return Oe(this,Re)}getY(){return Oe(this,Ee)}equals(e){return null!==e&&this.getX()===e.getX()&&this.getY()===e.getY()}toString(){return"("+this.getX()+", "+this.getY()+")"}getDistance(e){return Math.sqrt((this.getX()-e.getX())*(this.getX()-e.getX())+(this.getY()-e.getY())*(this.getY()-e.getY()))}getRound(){return new Me(Math.round(this.getX()),Math.round(this.getY()))}}var qe=new WeakMap,Ue=new WeakMap,Qe=new WeakMap;class ke{constructor(e,t,n){Ae(this,qe,{writable:!0,value:void 0}),Ae(this,Ue,{writable:!0,value:void 0}),Ae(this,Qe,{writable:!0,value:void 0}),xe(this,qe,e),xe(this,Ue,t),xe(this,Qe,n)}getX(){return Oe(this,qe)}getY(){return Oe(this,Ue)}getZ(){return Oe(this,Qe)}equals(e){return null!==e&&this.getX()===e.getX()&&this.getY()===e.getY()&&this.getZ()===e.getZ()}isSimilar(e,t){return null!==e&&we(this.getX(),e.getX(),t)&&we(this.getY(),e.getY(),t)&&we(this.getZ(),e.getZ(),t)}toString(){return"("+this.getX()+", "+this.getY()+", "+this.getZ()+")"}getDistance(e){return Math.sqrt((this.getX()-e.getX())*(this.getX()-e.getX())+(this.getY()-e.getY())*(this.getY()-e.getY())+(this.getZ()-e.getZ())*(this.getZ()-e.getZ()))}minus(e){return new pe(this.getX()-e.getX(),this.getY()-e.getY(),this.getZ()-e.getZ())}}var Be=new WeakMap;class Ne{constructor(e){if(Ae(this,Be,{writable:!0,value:void 0}),!e||void 0===e)throw new Error("Cannot create point with no values.");if(0===e.length)throw new Error("Cannot create point with empty values.");if(!e.every((function(e){return!isNaN(e)})))throw new Error("Cannot create point with non number values.");xe(this,Be,e)}get(e){return Oe(this,Be)[e]}length(){return Oe(this,Be).length}toString(){return"("+Oe(this,Be).toString()+")"}getValues(){return Oe(this,Be).slice()}canCompare(e){return!!e&&this.length()===e.length()}equals(e){if(!this.canCompare(e))return!1;for(let t=0,n=this.length();t<n;++t)if(this.get(t)!==e.get(t))return!1;return!0}compare(e){if(!this.canCompare(e))return null;const t=[];for(let n=0,i=this.length();n<i;++n)this.get(n)!==e.get(n)&&t.push(n);return t}get3D(){return new ke(this.get(0),this.get(1),this.get(2))}add(e){if(!this.canCompare(e))return null;const t=[],n=this.getValues(),i=e.getValues();for(let e=0;e<n.length;++e)t.push(n[e]+i[e]);return new Ne(t)}mergeWith3D(e){const t=this.getValues();return t[0]=e.getX(),t[1]=e.getY(),t[2]=e.getZ(),new Ne(t)}}const We={"0000":{"0000":["UL","1","CommandGroupLength"],"0001":["UL","1","CommandLengthToEnd"],"0002":["UI","1","AffectedSOPClassUID"],"0003":["UI","1","RequestedSOPClassUID"],"0010":["SH","1","CommandRecognitionCode"],"0100":["US","1","CommandField"],"0110":["US","1","MessageID"],"0120":["US","1","MessageIDBeingRespondedTo"],"0200":["AE","1","Initiator"],"0300":["AE","1","Receiver"],"0400":["AE","1","FindLocation"],"0600":["AE","1","MoveDestination"],"0700":["US","1","Priority"],"0800":["US","1","CommandDataSetType"],"0850":["US","1","NumberOfMatches"],"0860":["US","1","ResponseSequenceNumber"],"0900":["US","1","Status"],"0901":["AT","1-n","OffendingElement"],"0902":["LO","1","ErrorComment"],"0903":["US","1","ErrorID"],1e3:["UI","1","AffectedSOPInstanceUID"],1001:["UI","1","RequestedSOPInstanceUID"],1002:["US","1","EventTypeID"],1005:["AT","1-n","AttributeIdentifierList"],1008:["US","1","ActionTypeID"],1020:["US","1","NumberOfRemainingSuboperations"],1021:["US","1","NumberOfCompletedSuboperations"],1022:["US","1","NumberOfFailedSuboperations"],1023:["US","1","NumberOfWarningSuboperations"],1030:["AE","1","MoveOriginatorApplicationEntityTitle"],1031:["US","1","MoveOriginatorMessageID"],4e3:["LT","1","DialogReceiver"],4010:["LT","1","TerminalType"],5010:["SH","1","MessageSetID"],5020:["SH","1","EndMessageID"],5110:["LT","1","DisplayFormat"],5120:["LT","1","PagePositionID"],5130:["CS","1","TextFormatID"],5140:["CS","1","NormalReverse"],5150:["CS","1","AddGrayScale"],5160:["CS","1","Borders"],5170:["IS","1","Copies"],5180:["CS","1","CommandMagnificationType"],5190:["CS","1","Erase"],"51A0":["CS","1","Print"],"51B0":["US","1-n","Overlays"]},"0002":{"0000":["UL","1","FileMetaInformationGroupLength"],"0001":["OB","1","FileMetaInformationVersion"],"0002":["UI","1","MediaStorageSOPClassUID"],"0003":["UI","1","MediaStorageSOPInstanceUID"],"0010":["UI","1","TransferSyntaxUID"],"0012":["UI","1","ImplementationClassUID"],"0013":["SH","1","ImplementationVersionName"],"0016":["AE","1","SourceApplicationEntityTitle"],"0017":["AE","1","SendingApplicationEntityTitle"],"0018":["AE","1","ReceivingApplicationEntityTitle"],"0026":["UR","1","SourcePresentationAddress"],"0027":["UR","1","SendingPresentationAddress"],"0028":["UR","1","ReceivingPresentationAddress"],"0031":["OB","1","RTVMetaInformationVersion"],"0032":["UI","1","RTVCommunicationSOPClassUID"],"0033":["UI","1","RTVCommunicationSOPInstanceUID"],"0035":["OB","1","RTVSourceIdentifier"],"0036":["OB","1","RTVFlowIdentifier"],"0037":["UL","1","RTVFlowRTPSamplingRate"],"0038":["FD","1","RTVFlowActualFrameDuration"],"0100":["UI","1","PrivateInformationCreatorUID"],"0102":["OB","1","PrivateInformation"]},"0004":{"0000":["UL","1","GenericGroupLength"],1130:["CS","1","FileSetID"],1141:["CS","1-8","FileSetDescriptorFileID"],1142:["CS","1","SpecificCharacterSetOfFileSetDescriptorFile"],1200:["UL","1","OffsetOfTheFirstDirectoryRecordOfTheRootDirectoryEntity"],1202:["UL","1","OffsetOfTheLastDirectoryRecordOfTheRootDirectoryEntity"],1212:["US","1","FileSetConsistencyFlag"],1220:["SQ","1","DirectoryRecordSequence"],1400:["UL","1","OffsetOfTheNextDirectoryRecord"],1410:["US","1","RecordInUseFlag"],1420:["UL","1","OffsetOfReferencedLowerLevelDirectoryEntity"],1430:["CS","1","DirectoryRecordType"],1432:["UI","1","PrivateRecordUID"],1500:["CS","1-8","ReferencedFileID"],1504:["UL","1","MRDRDirectoryRecordOffset"],1510:["UI","1","ReferencedSOPClassUIDInFile"],1511:["UI","1","ReferencedSOPInstanceUIDInFile"],1512:["UI","1","ReferencedTransferSyntaxUIDInFile"],"151A":["UI","1-n","ReferencedRelatedGeneralSOPClassUIDInFile"],1600:["UL","1","NumberOfReferences"]},"0008":{"0000":["UL","1","GenericGroupLength"],"0001":["UL","1","LengthToEnd"],"0005":["CS","1-n","SpecificCharacterSet"],"0006":["SQ","1","LanguageCodeSequence"],"0008":["CS","2-n","ImageType"],"0010":["SH","1","RecognitionCode"],"0012":["DA","1","InstanceCreationDate"],"0013":["TM","1","InstanceCreationTime"],"0014":["UI","1","InstanceCreatorUID"],"0015":["DT","1","InstanceCoercionDateTime"],"0016":["UI","1","SOPClassUID"],"0018":["UI","1","SOPInstanceUID"],"001A":["UI","1-n","RelatedGeneralSOPClassUID"],"001B":["UI","1","OriginalSpecializedSOPClassUID"],"0020":["DA","1","StudyDate"],"0021":["DA","1","SeriesDate"],"0022":["DA","1","AcquisitionDate"],"0023":["DA","1","ContentDate"],"0024":["DA","1","OverlayDate"],"0025":["DA","1","CurveDate"],"002A":["DT","1","AcquisitionDateTime"],"0030":["TM","1","StudyTime"],"0031":["TM","1","SeriesTime"],"0032":["TM","1","AcquisitionTime"],"0033":["TM","1","ContentTime"],"0034":["TM","1","OverlayTime"],"0035":["TM","1","CurveTime"],"0040":["US","1","DataSetType"],"0041":["LO","1","DataSetSubtype"],"0042":["CS","1","NuclearMedicineSeriesType"],"0050":["SH","1","AccessionNumber"],"0051":["SQ","1","IssuerOfAccessionNumberSequence"],"0052":["CS","1","QueryRetrieveLevel"],"0053":["CS","1","QueryRetrieveView"],"0054":["AE","1-n","RetrieveAETitle"],"0055":["AE","1","StationAETitle"],"0056":["CS","1","InstanceAvailability"],"0058":["UI","1-n","FailedSOPInstanceUIDList"],"0060":["CS","1","Modality"],"0061":["CS","1-n","ModalitiesInStudy"],"0062":["UI","1-n","SOPClassesInStudy"],"0063":["SQ","1","AnatomicRegionsInStudyCodeSequence"],"0064":["CS","1","ConversionType"],"0068":["CS","1","PresentationIntentType"],"0070":["LO","1","Manufacturer"],"0080":["LO","1","InstitutionName"],"0081":["ST","1","InstitutionAddress"],"0082":["SQ","1","InstitutionCodeSequence"],"0090":["PN","1","ReferringPhysicianName"],"0092":["ST","1","ReferringPhysicianAddress"],"0094":["SH","1-n","ReferringPhysicianTelephoneNumbers"],"0096":["SQ","1","ReferringPhysicianIdentificationSequence"],"009C":["PN","1-n","ConsultingPhysicianName"],"009D":["SQ","1","ConsultingPhysicianIdentificationSequence"],"0100":["SH","1","CodeValue"],"0101":["LO","1","ExtendedCodeValue"],"0102":["SH","1","CodingSchemeDesignator"],"0103":["SH","1","CodingSchemeVersion"],"0104":["LO","1","CodeMeaning"],"0105":["CS","1","MappingResource"],"0106":["DT","1","ContextGroupVersion"],"0107":["DT","1","ContextGroupLocalVersion"],"0108":["LT","1","ExtendedCodeMeaning"],"0109":["SQ","1","CodingSchemeResourcesSequence"],"010A":["CS","1","CodingSchemeURLType"],"010B":["CS","1","ContextGroupExtensionFlag"],"010C":["UI","1","CodingSchemeUID"],"010D":["UI","1","ContextGroupExtensionCreatorUID"],"010E":["UR","1","CodingSchemeURL"],"010F":["CS","1","ContextIdentifier"],"0110":["SQ","1","CodingSchemeIdentificationSequence"],"0112":["LO","1","CodingSchemeRegistry"],"0114":["ST","1","CodingSchemeExternalID"],"0115":["ST","1","CodingSchemeName"],"0116":["ST","1","CodingSchemeResponsibleOrganization"],"0117":["UI","1","ContextUID"],"0118":["UI","1","MappingResourceUID"],"0119":["UC","1","LongCodeValue"],"0120":["UR","1","URNCodeValue"],"0121":["SQ","1","EquivalentCodeSequence"],"0122":["LO","1","MappingResourceName"],"0123":["SQ","1","ContextGroupIdentificationSequence"],"0124":["SQ","1","MappingResourceIdentificationSequence"],"0201":["SH","1","TimezoneOffsetFromUTC"],"0202":["","",""],"0220":["SQ","1","ResponsibleGroupCodeSequence"],"0221":["CS","1","EquipmentModality"],"0222":["LO","1","ManufacturerRelatedModelGroup"],"0300":["SQ","1","PrivateDataElementCharacteristicsSequence"],"0301":["US","1","PrivateGroupReference"],"0302":["LO","1","PrivateCreatorReference"],"0303":["CS","1","BlockIdentifyingInformationStatus"],"0304":["US","1-n","NonidentifyingPrivateElements"],"0305":["SQ","1","DeidentificationActionSequence"],"0306":["US","1-n","IdentifyingPrivateElements"],"0307":["CS","1","DeidentificationAction"],"0308":["US","1","PrivateDataElement"],"0309":["UL","1-3","PrivateDataElementValueMultiplicity"],"030A":["CS","1","PrivateDataElementValueRepresentation"],"030B":["UL","1-2","PrivateDataElementNumberOfItems"],"030C":["UC","1","PrivateDataElementName"],"030D":["UC","1","PrivateDataElementKeyword"],"030E":["UT","1","PrivateDataElementDescription"],"030F":["UT","1","PrivateDataElementEncoding"],"0310":["SQ","1","PrivateDataElementDefinitionSequence"],1e3:["AE","1","NetworkID"],1010:["SH","1","StationName"],1030:["LO","1","StudyDescription"],1032:["SQ","1","ProcedureCodeSequence"],"103E":["LO","1","SeriesDescription"],"103F":["SQ","1","SeriesDescriptionCodeSequence"],1040:["LO","1","InstitutionalDepartmentName"],1041:["SQ","1","InstitutionalDepartmentTypeCodeSequence"],1048:["PN","1-n","PhysiciansOfRecord"],1049:["SQ","1","PhysiciansOfRecordIdentificationSequence"],1050:["PN","1-n","PerformingPhysicianName"],1052:["SQ","1","PerformingPhysicianIdentificationSequence"],1060:["PN","1-n","NameOfPhysiciansReadingStudy"],1062:["SQ","1","PhysiciansReadingStudyIdentificationSequence"],1070:["PN","1-n","OperatorsName"],1072:["SQ","1","OperatorIdentificationSequence"],1080:["LO","1-n","AdmittingDiagnosesDescription"],1084:["SQ","1","AdmittingDiagnosesCodeSequence"],1090:["LO","1","ManufacturerModelName"],1100:["SQ","1","ReferencedResultsSequence"],1110:["SQ","1","ReferencedStudySequence"],1111:["SQ","1","ReferencedPerformedProcedureStepSequence"],1115:["SQ","1","ReferencedSeriesSequence"],1120:["SQ","1","ReferencedPatientSequence"],1125:["SQ","1","ReferencedVisitSequence"],1130:["SQ","1","ReferencedOverlaySequence"],1134:["SQ","1","ReferencedStereometricInstanceSequence"],"113A":["SQ","1","ReferencedWaveformSequence"],1140:["SQ","1","ReferencedImageSequence"],1145:["SQ","1","ReferencedCurveSequence"],"114A":["SQ","1","ReferencedInstanceSequence"],"114B":["SQ","1","ReferencedRealWorldValueMappingInstanceSequence"],1150:["UI","1","ReferencedSOPClassUID"],1155:["UI","1","ReferencedSOPInstanceUID"],1156:["SQ","1","DefinitionSourceSequence"],"115A":["UI","1-n","SOPClassesSupported"],1160:["IS","1-n","ReferencedFrameNumber"],1161:["UL","1-n","SimpleFrameList"],1162:["UL","3-3n","CalculatedFrameList"],1163:["FD","2","TimeRange"],1164:["SQ","1","FrameExtractionSequence"],1167:["UI","1","MultiFrameSourceSOPInstanceUID"],1190:["UR","1","RetrieveURL"],1195:["UI","1","TransactionUID"],1196:["US","1","WarningReason"],1197:["US","1","FailureReason"],1198:["SQ","1","FailedSOPSequence"],1199:["SQ","1","ReferencedSOPSequence"],"119A":["SQ","1","OtherFailuresSequence"],1200:["SQ","1","StudiesContainingOtherReferencedInstancesSequence"],1250:["SQ","1","RelatedSeriesSequence"],2110:["CS","1","LossyImageCompressionRetired"],2111:["ST","1","DerivationDescription"],2112:["SQ","1","SourceImageSequence"],2120:["SH","1","StageName"],2122:["IS","1","StageNumber"],2124:["IS","1","NumberOfStages"],2127:["SH","1","ViewName"],2128:["IS","1","ViewNumber"],2129:["IS","1","NumberOfEventTimers"],"212A":["IS","1","NumberOfViewsInStage"],2130:["DS","1-n","EventElapsedTimes"],2132:["LO","1-n","EventTimerNames"],2133:["SQ","1","EventTimerSequence"],2134:["FD","1","EventTimeOffset"],2135:["SQ","1","EventCodeSequence"],2142:["IS","1","StartTrim"],2143:["IS","1","StopTrim"],2144:["IS","1","RecommendedDisplayFrameRate"],2200:["CS","1","TransducerPosition"],2204:["CS","1","TransducerOrientation"],2208:["CS","1","AnatomicStructure"],2218:["SQ","1","AnatomicRegionSequence"],2220:["SQ","1","AnatomicRegionModifierSequence"],2228:["SQ","1","PrimaryAnatomicStructureSequence"],2229:["SQ","1","AnatomicStructureSpaceOrRegionSequence"],2230:["SQ","1","PrimaryAnatomicStructureModifierSequence"],2240:["SQ","1","TransducerPositionSequence"],2242:["SQ","1","TransducerPositionModifierSequence"],2244:["SQ","1","TransducerOrientationSequence"],2246:["SQ","1","TransducerOrientationModifierSequence"],2251:["SQ","1","AnatomicStructureSpaceOrRegionCodeSequenceTrial"],2253:["SQ","1","AnatomicPortalOfEntranceCodeSequenceTrial"],2255:["SQ","1","AnatomicApproachDirectionCodeSequenceTrial"],2256:["ST","1","AnatomicPerspectiveDescriptionTrial"],2257:["SQ","1","AnatomicPerspectiveCodeSequenceTrial"],2258:["ST","1","AnatomicLocationOfExaminingInstrumentDescriptionTrial"],2259:["SQ","1","AnatomicLocationOfExaminingInstrumentCodeSequenceTrial"],"225A":["SQ","1","AnatomicStructureSpaceOrRegionModifierCodeSequenceTrial"],"225C":["SQ","1","OnAxisBackgroundAnatomicStructureCodeSequenceTrial"],3001:["SQ","1","AlternateRepresentationSequence"],3002:["UI","1-n","AvailableTransferSyntaxUID"],3010:["UI","1-n","IrradiationEventUID"],3011:["SQ","1","SourceIrradiationEventSequence"],3012:["UI","1","RadiopharmaceuticalAdministrationEventUID"],4e3:["LT","1","IdentifyingComments"],9007:["CS","4","FrameType"],9092:["SQ","1","ReferencedImageEvidenceSequence"],9121:["SQ","1","ReferencedRawDataSequence"],9123:["UI","1","CreatorVersionUID"],9124:["SQ","1","DerivationImageSequence"],9154:["SQ","1","SourceImageEvidenceSequence"],9205:["CS","1","PixelPresentation"],9206:["CS","1","VolumetricProperties"],9207:["CS","1","VolumeBasedCalculationTechnique"],9208:["CS","1","ComplexImageComponent"],9209:["CS","1","AcquisitionContrast"],9215:["SQ","1","DerivationCodeSequence"],9237:["SQ","1","ReferencedPresentationStateSequence"],9410:["SQ","1","ReferencedOtherPlaneSequence"],9458:["SQ","1","FrameDisplaySequence"],9459:["FL","1","RecommendedDisplayFrameRateInFloat"],9460:["CS","1","SkipFrameRangeFlag"]},"0010":{"0000":["UL","1","GenericGroupLength"],"0010":["PN","1","PatientName"],"0020":["LO","1","PatientID"],"0021":["LO","1","IssuerOfPatientID"],"0022":["CS","1","TypeOfPatientID"],"0024":["SQ","1","IssuerOfPatientIDQualifiersSequence"],"0026":["SQ","1","SourcePatientGroupIdentificationSequence"],"0027":["SQ","1","GroupOfPatientsIdentificationSequence"],"0028":["US","3","SubjectRelativePositionInImage"],"0030":["DA","1","PatientBirthDate"],"0032":["TM","1","PatientBirthTime"],"0033":["LO","1","PatientBirthDateInAlternativeCalendar"],"0034":["LO","1","PatientDeathDateInAlternativeCalendar"],"0035":["CS","1","PatientAlternativeCalendar"],"0040":["CS","1","PatientSex"],"0050":["SQ","1","PatientInsurancePlanCodeSequence"],"0101":["SQ","1","PatientPrimaryLanguageCodeSequence"],"0102":["SQ","1","PatientPrimaryLanguageModifierCodeSequence"],"0200":["CS","1","QualityControlSubject"],"0201":["SQ","1","QualityControlSubjectTypeCodeSequence"],"0212":["UC","1","StrainDescription"],"0213":["LO","1","StrainNomenclature"],"0214":["LO","1","StrainStockNumber"],"0215":["SQ","1","StrainSourceRegistryCodeSequence"],"0216":["SQ","1","StrainStockSequence"],"0217":["LO","1","StrainSource"],"0218":["UT","1","StrainAdditionalInformation"],"0219":["SQ","1","StrainCodeSequence"],"0221":["SQ","1","GeneticModificationsSequence"],"0222":["UC","1","GeneticModificationsDescription"],"0223":["LO","1","GeneticModificationsNomenclature"],"0229":["SQ","1","GeneticModificationsCodeSequence"],1e3:["LO","1-n","OtherPatientIDs"],1001:["PN","1-n","OtherPatientNames"],1002:["SQ","1","OtherPatientIDsSequence"],1005:["PN","1","PatientBirthName"],1010:["AS","1","PatientAge"],1020:["DS","1","PatientSize"],1021:["SQ","1","PatientSizeCodeSequence"],1022:["DS","1","PatientBodyMassIndex"],1023:["DS","1","MeasuredAPDimension"],1024:["DS","1","MeasuredLateralDimension"],1030:["DS","1","PatientWeight"],1040:["LO","1","PatientAddress"],1050:["LO","1-n","InsurancePlanIdentification"],1060:["PN","1","PatientMotherBirthName"],1080:["LO","1","MilitaryRank"],1081:["LO","1","BranchOfService"],1090:["LO","1","MedicalRecordLocator"],1100:["SQ","1","ReferencedPatientPhotoSequence"],2e3:["LO","1-n","MedicalAlerts"],2110:["LO","1-n","Allergies"],2150:["LO","1","CountryOfResidence"],2152:["LO","1","RegionOfResidence"],2154:["SH","1-n","PatientTelephoneNumbers"],2155:["LT","1","PatientTelecomInformation"],2160:["SH","1","EthnicGroup"],2180:["SH","1","Occupation"],"21A0":["CS","1","SmokingStatus"],"21B0":["LT","1","AdditionalPatientHistory"],"21C0":["US","1","PregnancyStatus"],"21D0":["DA","1","LastMenstrualDate"],"21F0":["LO","1","PatientReligiousPreference"],2201:["LO","1","PatientSpeciesDescription"],2202:["SQ","1","PatientSpeciesCodeSequence"],2203:["CS","1","PatientSexNeutered"],2210:["CS","1","AnatomicalOrientationType"],2292:["LO","1","PatientBreedDescription"],2293:["SQ","1","PatientBreedCodeSequence"],2294:["SQ","1","BreedRegistrationSequence"],2295:["LO","1","BreedRegistrationNumber"],2296:["SQ","1","BreedRegistryCodeSequence"],2297:["PN","1","ResponsiblePerson"],2298:["CS","1","ResponsiblePersonRole"],2299:["LO","1","ResponsibleOrganization"],4e3:["LT","1","PatientComments"],9431:["FL","1","ExaminedBodyThickness"]},"0012":{"0000":["UL","1","GenericGroupLength"],"0010":["LO","1","ClinicalTrialSponsorName"],"0020":["LO","1","ClinicalTrialProtocolID"],"0021":["LO","1","ClinicalTrialProtocolName"],"0030":["LO","1","ClinicalTrialSiteID"],"0031":["LO","1","ClinicalTrialSiteName"],"0040":["LO","1","ClinicalTrialSubjectID"],"0042":["LO","1","ClinicalTrialSubjectReadingID"],"0050":["LO","1","ClinicalTrialTimePointID"],"0051":["ST","1","ClinicalTrialTimePointDescription"],"0052":["FD","1","LongitudinalTemporalOffsetFromEvent"],"0053":["CS","1","LongitudinalTemporalEventType"],"0060":["LO","1","ClinicalTrialCoordinatingCenterName"],"0062":["CS","1","PatientIdentityRemoved"],"0063":["LO","1-n","DeidentificationMethod"],"0064":["SQ","1","DeidentificationMethodCodeSequence"],"0071":["LO","1","ClinicalTrialSeriesID"],"0072":["LO","1","ClinicalTrialSeriesDescription"],"0081":["LO","1","ClinicalTrialProtocolEthicsCommitteeName"],"0082":["LO","1","ClinicalTrialProtocolEthicsCommitteeApprovalNumber"],"0083":["SQ","1","ConsentForClinicalTrialUseSequence"],"0084":["CS","1","DistributionType"],"0085":["CS","1","ConsentForDistributionFlag"],"0086":["DA","1","EthicsCommitteeApprovalEffectivenessStartDate"],"0087":["DA","1","EthicsCommitteeApprovalEffectivenessEndDate"]},"0014":{"0000":["UL","1","GenericGroupLength"],"0023":["ST","1","CADFileFormat"],"0024":["ST","1","ComponentReferenceSystem"],"0025":["ST","1","ComponentManufacturingProcedure"],"0028":["ST","1","ComponentManufacturer"],"0030":["DS","1-n","MaterialThickness"],"0032":["DS","1-n","MaterialPipeDiameter"],"0034":["DS","1-n","MaterialIsolationDiameter"],"0042":["ST","1","MaterialGrade"],"0044":["ST","1","MaterialPropertiesDescription"],"0045":["ST","1","MaterialPropertiesFileFormatRetired"],"0046":["LT","1","MaterialNotes"],"0050":["CS","1","ComponentShape"],"0052":["CS","1","CurvatureType"],"0054":["DS","1","OuterDiameter"],"0056":["DS","1","InnerDiameter"],"0100":["LO","1-n","ComponentWelderIDs"],"0101":["CS","1","SecondaryApprovalStatus"],"0102":["DA","1","SecondaryReviewDate"],"0103":["TM","1","SecondaryReviewTime"],"0104":["PN","1","SecondaryReviewerName"],"0105":["ST","1","RepairID"],"0106":["SQ","1","MultipleComponentApprovalSequence"],"0107":["CS","1-n","OtherApprovalStatus"],"0108":["CS","1-n","OtherSecondaryApprovalStatus"],1010:["ST","1","ActualEnvironmentalConditions"],1020:["DA","1","ExpiryDate"],1040:["ST","1","EnvironmentalConditions"],2002:["SQ","1","EvaluatorSequence"],2004:["IS","1","EvaluatorNumber"],2006:["PN","1","EvaluatorName"],2008:["IS","1","EvaluationAttempt"],2012:["SQ","1","IndicationSequence"],2014:["IS","1","IndicationNumber"],2016:["SH","1","IndicationLabel"],2018:["ST","1","IndicationDescription"],"201A":["CS","1-n","IndicationType"],"201C":["CS","1","IndicationDisposition"],"201E":["SQ","1","IndicationROISequence"],2030:["SQ","1","IndicationPhysicalPropertySequence"],2032:["SH","1","PropertyLabel"],2202:["IS","1","CoordinateSystemNumberOfAxes"],2204:["SQ","1","CoordinateSystemAxesSequence"],2206:["ST","1","CoordinateSystemAxisDescription"],2208:["CS","1","CoordinateSystemDataSetMapping"],"220A":["IS","1","CoordinateSystemAxisNumber"],"220C":["CS","1","CoordinateSystemAxisType"],"220E":["CS","1","CoordinateSystemAxisUnits"],2210:["OB","1","CoordinateSystemAxisValues"],2220:["SQ","1","CoordinateSystemTransformSequence"],2222:["ST","1","TransformDescription"],2224:["IS","1","TransformNumberOfAxes"],2226:["IS","1-n","TransformOrderOfAxes"],2228:["CS","1","TransformedAxisUnits"],"222A":["DS","1-n","CoordinateSystemTransformRotationAndScaleMatrix"],"222C":["DS","1-n","CoordinateSystemTransformTranslationMatrix"],3011:["DS","1","InternalDetectorFrameTime"],3012:["DS","1","NumberOfFramesIntegrated"],3020:["SQ","1","DetectorTemperatureSequence"],3022:["ST","1","SensorName"],3024:["DS","1","HorizontalOffsetOfSensor"],3026:["DS","1","VerticalOffsetOfSensor"],3028:["DS","1","SensorTemperature"],3040:["SQ","1","DarkCurrentSequence"],3050:["ox","1","DarkCurrentCounts"],3060:["SQ","1","GainCorrectionReferenceSequence"],3070:["ox","1","AirCounts"],3071:["DS","1","KVUsedInGainCalibration"],3072:["DS","1","MAUsedInGainCalibration"],3073:["DS","1","NumberOfFramesUsedForIntegration"],3074:["LO","1","FilterMaterialUsedInGainCalibration"],3075:["DS","1","FilterThicknessUsedInGainCalibration"],3076:["DA","1","DateOfGainCalibration"],3077:["TM","1","TimeOfGainCalibration"],3080:["OB","1","BadPixelImage"],3099:["LT","1","CalibrationNotes"],3100:["LT","1","LinearityCorrectionTechnique"],3101:["LT","1","BeamHardeningCorrectionTechnique"],4002:["SQ","1","PulserEquipmentSequence"],4004:["CS","1","PulserType"],4006:["LT","1","PulserNotes"],4008:["SQ","1","ReceiverEquipmentSequence"],"400A":["CS","1","AmplifierType"],"400C":["LT","1","ReceiverNotes"],"400E":["SQ","1","PreAmplifierEquipmentSequence"],"400F":["LT","1","PreAmplifierNotes"],4010:["SQ","1","TransmitTransducerSequence"],4011:["SQ","1","ReceiveTransducerSequence"],4012:["US","1","NumberOfElements"],4013:["CS","1","ElementShape"],4014:["DS","1","ElementDimensionA"],4015:["DS","1","ElementDimensionB"],4016:["DS","1","ElementPitchA"],4017:["DS","1","MeasuredBeamDimensionA"],4018:["DS","1","MeasuredBeamDimensionB"],4019:["DS","1","LocationOfMeasuredBeamDiameter"],"401A":["DS","1","NominalFrequency"],"401B":["DS","1","MeasuredCenterFrequency"],"401C":["DS","1","MeasuredBandwidth"],"401D":["DS","1","ElementPitchB"],4020:["SQ","1","PulserSettingsSequence"],4022:["DS","1","PulseWidth"],4024:["DS","1","ExcitationFrequency"],4026:["CS","1","ModulationType"],4028:["DS","1","Damping"],4030:["SQ","1","ReceiverSettingsSequence"],4031:["DS","1","AcquiredSoundpathLength"],4032:["CS","1","AcquisitionCompressionType"],4033:["IS","1","AcquisitionSampleSize"],4034:["DS","1","RectifierSmoothing"],4035:["SQ","1","DACSequence"],4036:["CS","1","DACType"],4038:["DS","1-n","DACGainPoints"],"403A":["DS","1-n","DACTimePoints"],"403C":["DS","1-n","DACAmplitude"],4040:["SQ","1","PreAmplifierSettingsSequence"],4050:["SQ","1","TransmitTransducerSettingsSequence"],4051:["SQ","1","ReceiveTransducerSettingsSequence"],4052:["DS","1","IncidentAngle"],4054:["ST","1","CouplingTechnique"],4056:["ST","1","CouplingMedium"],4057:["DS","1","CouplingVelocity"],4058:["DS","1","ProbeCenterLocationX"],4059:["DS","1","ProbeCenterLocationZ"],"405A":["DS","1","SoundPathLength"],"405C":["ST","1","DelayLawIdentifier"],4060:["SQ","1","GateSettingsSequence"],4062:["DS","1","GateThreshold"],4064:["DS","1","VelocityOfSound"],4070:["SQ","1","CalibrationSettingsSequence"],4072:["ST","1","CalibrationProcedure"],4074:["SH","1","ProcedureVersion"],4076:["DA","1","ProcedureCreationDate"],4078:["DA","1","ProcedureExpirationDate"],"407A":["DA","1","ProcedureLastModifiedDate"],"407C":["TM","1-n","CalibrationTime"],"407E":["DA","1-n","CalibrationDate"],4080:["SQ","1","ProbeDriveEquipmentSequence"],4081:["CS","1","DriveType"],4082:["LT","1","ProbeDriveNotes"],4083:["SQ","1","DriveProbeSequence"],4084:["DS","1","ProbeInductance"],4085:["DS","1","ProbeResistance"],4086:["SQ","1","ReceiveProbeSequence"],4087:["SQ","1","ProbeDriveSettingsSequence"],4088:["DS","1","BridgeResistors"],4089:["DS","1","ProbeOrientationAngle"],"408B":["DS","1","UserSelectedGainY"],"408C":["DS","1","UserSelectedPhase"],"408D":["DS","1","UserSelectedOffsetX"],"408E":["DS","1","UserSelectedOffsetY"],4091:["SQ","1","ChannelSettingsSequence"],4092:["DS","1","ChannelThreshold"],"409A":["SQ","1","ScannerSettingsSequence"],"409B":["ST","1","ScanProcedure"],"409C":["DS","1","TranslationRateX"],"409D":["DS","1","TranslationRateY"],"409F":["DS","1","ChannelOverlap"],"40A0":["LO","1-n","ImageQualityIndicatorType"],"40A1":["LO","1-n","ImageQualityIndicatorMaterial"],"40A2":["LO","1-n","ImageQualityIndicatorSize"],5002:["IS","1","LINACEnergy"],5004:["IS","1","LINACOutput"],5100:["US","1","ActiveAperture"],5101:["DS","1","TotalAperture"],5102:["DS","1","ApertureElevation"],5103:["DS","1","MainLobeAngle"],5104:["DS","1","MainRoofAngle"],5105:["CS","1","ConnectorType"],5106:["SH","1","WedgeModelNumber"],5107:["DS","1","WedgeAngleFloat"],5108:["DS","1","WedgeRoofAngle"],5109:["CS","1","WedgeElement1Position"],"510A":["DS","1","WedgeMaterialVelocity"],"510B":["SH","1","WedgeMaterial"],"510C":["DS","1","WedgeOffsetZ"],"510D":["DS","1","WedgeOriginOffsetX"],"510E":["DS","1","WedgeTimeDelay"],"510F":["SH","1","WedgeName"],5110:["SH","1","WedgeManufacturerName"],5111:["LO","1","WedgeDescription"],5112:["DS","1","NominalBeamAngle"],5113:["DS","1","WedgeOffsetX"],5114:["DS","1","WedgeOffsetY"],5115:["DS","1","WedgeTotalLength"],5116:["DS","1","WedgeInContactLength"],5117:["DS","1","WedgeFrontGap"],5118:["DS","1","WedgeTotalHeight"],5119:["DS","1","WedgeFrontHeight"],"511A":["DS","1","WedgeRearHeight"],"511B":["DS","1","WedgeTotalWidth"],"511C":["DS","1","WedgeInContactWidth"],"511D":["DS","1","WedgeChamferHeight"],"511E":["CS","1","WedgeCurve"],"511F":["DS","1","RadiusAlongWedge"]},"0016":{"0000":["UL","1","GenericGroupLength"],"0001":["DS","1","WhitePoint"],"0002":["DS","3","PrimaryChromaticities"],"0003":["UT","1","BatteryLevel"],"0004":["DS","1","ExposureTimeInSeconds"],"0005":["DS","1","FNumber"],"0006":["IS","1","OECFRows"],"0007":["IS","1","OECFColumns"],"0008":["UC","1-n","OECFColumnNames"],"0009":["DS","1-n","OECFValues"],"000A":["IS","1","SpatialFrequencyResponseRows"],"000B":["IS","1","SpatialFrequencyResponseColumns"],"000C":["UC","1-n","SpatialFrequencyResponseColumnNames"],"000D":["DS","1-n","SpatialFrequencyResponseValues"],"000E":["IS","1","ColorFilterArrayPatternRows"],"000F":["IS","1","ColorFilterArrayPatternColumns"],"0010":["DS","1-n","ColorFilterArrayPatternValues"],"0011":["US","1","FlashFiringStatus"],"0012":["US","1","FlashReturnStatus"],"0013":["US","1","FlashMode"],"0014":["US","1","FlashFunctionPresent"],"0015":["US","1","FlashRedEyeMode"],"0016":["US","1","ExposureProgram"],"0017":["UT","1","SpectralSensitivity"],"0018":["IS","1","PhotographicSensitivity"],"0019":["IS","1","SelfTimerMode"],"001A":["US","1","SensitivityType"],"001B":["IS","1","StandardOutputSensitivity"],"001C":["IS","1","RecommendedExposureIndex"],"001D":["IS","1","ISOSpeed"],"001E":["IS","1","ISOSpeedLatitudeyyy"],"001F":["IS","1","ISOSpeedLatitudezzz"],"0020":["UT","1","EXIFVersion"],"0021":["DS","1","ShutterSpeedValue"],"0022":["DS","1","ApertureValue"],"0023":["DS","1","BrightnessValue"],"0024":["DS","1","ExposureBiasValue"],"0025":["DS","1","MaxApertureValue"],"0026":["DS","1","SubjectDistance"],"0027":["US","1","MeteringMode"],"0028":["US","1","LightSource"],"0029":["DS","1","FocalLength"],"002A":["IS","2-4","SubjectArea"],"002B":["OB","1","MakerNote"],"0030":["DS","1","Temperature"],"0031":["DS","1","Humidity"],"0032":["DS","1","Pressure"],"0033":["DS","1","WaterDepth"],"0034":["DS","1","Acceleration"],"0035":["DS","1","CameraElevationAngle"],"0036":["DS","1-2","FlashEnergy"],"0037":["IS","2","SubjectLocation"],"0038":["DS","1","PhotographicExposureIndex"],"0039":["US","1","SensingMethod"],"003A":["US","1","FileSource"],"003B":["US","1","SceneType"],"0041":["US","1","CustomRendered"],"0042":["US","1","ExposureMode"],"0043":["US","1","WhiteBalance"],"0044":["DS","1","DigitalZoomRatio"],"0045":["IS","1","FocalLengthIn35mmFilm"],"0046":["US","1","SceneCaptureType"],"0047":["US","1","GainControl"],"0048":["US","1","Contrast"],"0049":["US","1","Saturation"],"004A":["US","1","Sharpness"],"004B":["OB","1","DeviceSettingDescription"],"004C":["US","1","SubjectDistanceRange"],"004D":["UT","1","CameraOwnerName"],"004E":["DS","4","LensSpecification"],"004F":["UT","1","LensMake"],"0050":["UT","1","LensModel"],"0051":["UT","1","LensSerialNumber"],"0061":["CS","1","InteroperabilityIndex"],"0062":["OB","1","InteroperabilityVersion"],"0070":["OB","1","GPSVersionID"],"0071":["CS","1","GPSLatitudeRef"],"0072":["DS","3","GPSLatitude"],"0073":["CS","1","GPSLongitudeRef"],"0074":["DS","3","GPSLongitude"],"0075":["US","1","GPSAltitudeRef"],"0076":["DS","1","GPSAltitude"],"0077":["DT","1","GPSTimeStamp"],"0078":["UT","1","GPSSatellites"],"0079":["CS","1","GPSStatus"],"007A":["CS","1","GPSMeasureMode"],"007B":["DS","1","GPSDOP"],"007C":["CS","1","GPSSpeedRef"],"007D":["DS","1","GPSSpeed"],"007E":["CS","1","GPSTrackRef"],"007F":["DS","1","GPSTrack"],"0080":["CS","1","GPSImgDirectionRef"],"0081":["DS","1","GPSImgDirection"],"0082":["UT","1","GPSMapDatum"],"0083":["CS","1","GPSDestLatitudeRef"],"0084":["DS","3","GPSDestLatitude"],"0085":["CS","1","GPSDestLongitudeRef"],"0086":["DS","3","GPSDestLongitude"],"0087":["CS","1","GPSDestBearingRef"],"0088":["DS","1","GPSDestBearing"],"0089":["CS","1","GPSDestDistanceRef"],"008A":["DS","1","GPSDestDistance"],"008B":["OB","1","GPSProcessingMethod"],"008C":["OB","1","GPSAreaInformation"],"008D":["DT","1","GPSDateStamp"],"008E":["IS","1","GPSDifferential"],1001:["CS","1","LightSourcePolarization"],1002:["DS","1","EmitterColorTemperature"],1003:["CS","1","ContactMethod"],1004:["CS","1-n","ImmersionMedia"],1005:["DS","1","OpticalMagnificationFactor"]},"0018":{"0000":["UL","1","GenericGroupLength"],"0010":["LO","1","ContrastBolusAgent"],"0012":["SQ","1","ContrastBolusAgentSequence"],"0013":["FL","1","ContrastBolusT1Relaxivity"],"0014":["SQ","1","ContrastBolusAdministrationRouteSequence"],"0015":["CS","1","BodyPartExamined"],"0020":["CS","1-n","ScanningSequence"],"0021":["CS","1-n","SequenceVariant"],"0022":["CS","1-n","ScanOptions"],"0023":["CS","1","MRAcquisitionType"],"0024":["SH","1","SequenceName"],"0025":["CS","1","AngioFlag"],"0026":["SQ","1","InterventionDrugInformationSequence"],"0027":["TM","1","InterventionDrugStopTime"],"0028":["DS","1","InterventionDrugDose"],"0029":["SQ","1","InterventionDrugCodeSequence"],"002A":["SQ","1","AdditionalDrugSequence"],"0030":["LO","1-n","Radionuclide"],"0031":["LO","1","Radiopharmaceutical"],"0032":["DS","1","EnergyWindowCenterline"],"0033":["DS","1-n","EnergyWindowTotalWidth"],"0034":["LO","1","InterventionDrugName"],"0035":["TM","1","InterventionDrugStartTime"],"0036":["SQ","1","InterventionSequence"],"0037":["CS","1","TherapyType"],"0038":["CS","1","InterventionStatus"],"0039":["CS","1","TherapyDescription"],"003A":["ST","1","InterventionDescription"],"0040":["IS","1","CineRate"],"0042":["CS","1","InitialCineRunState"],"0050":["DS","1","SliceThickness"],"0060":["DS","1","KVP"],"0061":["DS","1",""],"0070":["IS","1","CountsAccumulated"],"0071":["CS","1","AcquisitionTerminationCondition"],"0072":["DS","1","EffectiveDuration"],"0073":["CS","1","AcquisitionStartCondition"],"0074":["IS","1","AcquisitionStartConditionData"],"0075":["IS","1","AcquisitionTerminationConditionData"],"0080":["DS","1","RepetitionTime"],"0081":["DS","1","EchoTime"],"0082":["DS","1","InversionTime"],"0083":["DS","1","NumberOfAverages"],"0084":["DS","1","ImagingFrequency"],"0085":["SH","1","ImagedNucleus"],"0086":["IS","1-n","EchoNumbers"],"0087":["DS","1","MagneticFieldStrength"],"0088":["DS","1","SpacingBetweenSlices"],"0089":["IS","1","NumberOfPhaseEncodingSteps"],"0090":["DS","1","DataCollectionDiameter"],"0091":["IS","1","EchoTrainLength"],"0093":["DS","1","PercentSampling"],"0094":["DS","1","PercentPhaseFieldOfView"],"0095":["DS","1","PixelBandwidth"],1e3:["LO","1","DeviceSerialNumber"],1002:["UI","1","DeviceUID"],1003:["LO","1","DeviceID"],1004:["LO","1","PlateID"],1005:["LO","1","GeneratorID"],1006:["LO","1","GridID"],1007:["LO","1","CassetteID"],1008:["LO","1","GantryID"],1009:["UT","1","UniqueDeviceIdentifier"],"100A":["SQ","1","UDISequence"],"100B":["UI","1-n","ManufacturerDeviceClassUID"],1010:["LO","1","SecondaryCaptureDeviceID"],1011:["LO","1","HardcopyCreationDeviceID"],1012:["DA","1","DateOfSecondaryCapture"],1014:["TM","1","TimeOfSecondaryCapture"],1016:["LO","1","SecondaryCaptureDeviceManufacturer"],1017:["LO","1","HardcopyDeviceManufacturer"],1018:["LO","1","SecondaryCaptureDeviceManufacturerModelName"],1019:["LO","1-n","SecondaryCaptureDeviceSoftwareVersions"],"101A":["LO","1-n","HardcopyDeviceSoftwareVersion"],"101B":["LO","1","HardcopyDeviceManufacturerModelName"],1020:["LO","1-n","SoftwareVersions"],1022:["SH","1","VideoImageFormatAcquired"],1023:["LO","1","DigitalImageFormatAcquired"],1030:["LO","1","ProtocolName"],1040:["LO","1","ContrastBolusRoute"],1041:["DS","1","ContrastBolusVolume"],1042:["TM","1","ContrastBolusStartTime"],1043:["TM","1","ContrastBolusStopTime"],1044:["DS","1","ContrastBolusTotalDose"],1045:["IS","1","SyringeCounts"],1046:["DS","1-n","ContrastFlowRate"],1047:["DS","1-n","ContrastFlowDuration"],1048:["CS","1","ContrastBolusIngredient"],1049:["DS","1","ContrastBolusIngredientConcentration"],1050:["DS","1","SpatialResolution"],1060:["DS","1","TriggerTime"],1061:["LO","1","TriggerSourceOrType"],1062:["IS","1","NominalInterval"],1063:["DS","1","FrameTime"],1064:["LO","1","CardiacFramingType"],1065:["DS","1-n","FrameTimeVector"],1066:["DS","1","FrameDelay"],1067:["DS","1","ImageTriggerDelay"],1068:["DS","1","MultiplexGroupTimeOffset"],1069:["DS","1","TriggerTimeOffset"],"106A":["CS","1","SynchronizationTrigger"],"106C":["US","2","SynchronizationChannel"],"106E":["UL","1","TriggerSamplePosition"],1070:["LO","1","RadiopharmaceuticalRoute"],1071:["DS","1","RadiopharmaceuticalVolume"],1072:["TM","1","RadiopharmaceuticalStartTime"],1073:["TM","1","RadiopharmaceuticalStopTime"],1074:["DS","1","RadionuclideTotalDose"],1075:["DS","1","RadionuclideHalfLife"],1076:["DS","1","RadionuclidePositronFraction"],1077:["DS","1","RadiopharmaceuticalSpecificActivity"],1078:["DT","1","RadiopharmaceuticalStartDateTime"],1079:["DT","1","RadiopharmaceuticalStopDateTime"],1080:["CS","1","BeatRejectionFlag"],1081:["IS","1","LowRRValue"],1082:["IS","1","HighRRValue"],1083:["IS","1","IntervalsAcquired"],1084:["IS","1","IntervalsRejected"],1085:["LO","1","PVCRejection"],1086:["IS","1","SkipBeats"],1088:["IS","1","HeartRate"],1090:["IS","1","CardiacNumberOfImages"],1094:["IS","1","TriggerWindow"],1100:["DS","1","ReconstructionDiameter"],1110:["DS","1","DistanceSourceToDetector"],1111:["DS","1","DistanceSourceToPatient"],1114:["DS","1","EstimatedRadiographicMagnificationFactor"],1120:["DS","1","GantryDetectorTilt"],1121:["DS","1","GantryDetectorSlew"],1130:["DS","1","TableHeight"],1131:["DS","1","TableTraverse"],1134:["CS","1","TableMotion"],1135:["DS","1-n","TableVerticalIncrement"],1136:["DS","1-n","TableLateralIncrement"],1137:["DS","1-n","TableLongitudinalIncrement"],1138:["DS","1","TableAngle"],"113A":["CS","1","TableType"],1140:["CS","1","RotationDirection"],1141:["DS","1","AngularPosition"],1142:["DS","1-n","RadialPosition"],1143:["DS","1","ScanArc"],1144:["DS","1","AngularStep"],1145:["DS","1","CenterOfRotationOffset"],1146:["DS","1-n","RotationOffset"],1147:["CS","1","FieldOfViewShape"],1149:["IS","1-2","FieldOfViewDimensions"],1150:["IS","1","ExposureTime"],1151:["IS","1","XRayTubeCurrent"],1152:["IS","1","Exposure"],1153:["IS","1","ExposureInuAs"],1154:["DS","1","AveragePulseWidth"],1155:["CS","1","RadiationSetting"],1156:["CS","1","RectificationType"],"115A":["CS","1","RadiationMode"],"115E":["DS","1","ImageAndFluoroscopyAreaDoseProduct"],1160:["SH","1","FilterType"],1161:["LO","1-n","TypeOfFilters"],1162:["DS","1","IntensifierSize"],1164:["DS","2","ImagerPixelSpacing"],1166:["CS","1-n","Grid"],1170:["IS","1","GeneratorPower"],1180:["SH","1","CollimatorGridName"],1181:["CS","1","CollimatorType"],1182:["IS","1-2","FocalDistance"],1183:["DS","1-2","XFocusCenter"],1184:["DS","1-2","YFocusCenter"],1190:["DS","1-n","FocalSpots"],1191:["CS","1","AnodeTargetMaterial"],"11A0":["DS","1","BodyPartThickness"],"11A2":["DS","1","CompressionForce"],"11A3":["DS","1","CompressionPressure"],"11A4":["LO","1","PaddleDescription"],"11A5":["DS","1","CompressionContactArea"],"11B0":["LO","1","AcquisitionMode"],"11B1":["LO","1","DoseModeName"],"11B2":["CS","1","AcquiredSubtractionMaskFlag"],"11B3":["CS","1","FluoroscopyPersistenceFlag"],"11B4":["CS","1","FluoroscopyLastImageHoldPersistenceFlag"],"11B5":["IS","1","UpperLimitNumberOfPersistentFluoroscopyFrames"],"11B6":["CS","1","ContrastBolusAutoInjectionTriggerFlag"],"11B7":["FD","1","ContrastBolusInjectionDelay"],"11B8":["SQ","1","XAAcquisitionPhaseDetailsSequence"],"11B9":["FD","1","XAAcquisitionFrameRate"],"11BA":["SQ","1","XAPlaneDetailsSequence"],"11BB":["LO","1","AcquisitionFieldOfViewLabel"],"11BC":["SQ","1","XRayFilterDetailsSequence"],"11BD":["FD","1","XAAcquisitionDuration"],"11BE":["CS","1","ReconstructionPipelineType"],"11BF":["SQ","1","ImageFilterDetailsSequence"],"11C0":["CS","1","AppliedMaskSubtractionFlag"],"11C1":["SQ","1","RequestedSeriesDescriptionCodeSequence"],1200:["DA","1-n","DateOfLastCalibration"],1201:["TM","1-n","TimeOfLastCalibration"],1202:["DT","1","DateTimeOfLastCalibration"],1203:["DT","1","CalibrationDateTime"],1210:["SH","1-n","ConvolutionKernel"],1240:["IS","1-n","UpperLowerPixelValues"],1242:["IS","1","ActualFrameDuration"],1243:["IS","1","CountRate"],1244:["US","1","PreferredPlaybackSequencing"],1250:["SH","1","ReceiveCoilName"],1251:["SH","1","TransmitCoilName"],1260:["SH","1","PlateType"],1261:["LO","1","PhosphorType"],1271:["FD","1","WaterEquivalentDiameter"],1272:["SQ","1","WaterEquivalentDiameterCalculationMethodCodeSequence"],1300:["DS","1","ScanVelocity"],1301:["CS","1-n","WholeBodyTechnique"],1302:["IS","1","ScanLength"],1310:["US","4","AcquisitionMatrix"],1312:["CS","1","InPlanePhaseEncodingDirection"],1314:["DS","1","FlipAngle"],1315:["CS","1","VariableFlipAngleFlag"],1316:["DS","1","SAR"],1318:["DS","1","dBdt"],1320:["FL","1","B1rms"],1400:["LO","1","AcquisitionDeviceProcessingDescription"],1401:["LO","1","AcquisitionDeviceProcessingCode"],1402:["CS","1","CassetteOrientation"],1403:["CS","1","CassetteSize"],1404:["US","1","ExposuresOnPlate"],1405:["IS","1","RelativeXRayExposure"],1411:["DS","1","ExposureIndex"],1412:["DS","1","TargetExposureIndex"],1413:["DS","1","DeviationIndex"],1450:["DS","1","ColumnAngulation"],1460:["DS","1","TomoLayerHeight"],1470:["DS","1","TomoAngle"],1480:["DS","1","TomoTime"],1490:["CS","1","TomoType"],1491:["CS","1","TomoClass"],1495:["IS","1","NumberOfTomosynthesisSourceImages"],1500:["CS","1","PositionerMotion"],1508:["CS","1","PositionerType"],1510:["DS","1","PositionerPrimaryAngle"],1511:["DS","1","PositionerSecondaryAngle"],1520:["DS","1-n","PositionerPrimaryAngleIncrement"],1521:["DS","1-n","PositionerSecondaryAngleIncrement"],1530:["DS","1","DetectorPrimaryAngle"],1531:["DS","1","DetectorSecondaryAngle"],1600:["CS","1-3","ShutterShape"],1602:["IS","1","ShutterLeftVerticalEdge"],1604:["IS","1","ShutterRightVerticalEdge"],1606:["IS","1","ShutterUpperHorizontalEdge"],1608:["IS","1","ShutterLowerHorizontalEdge"],1610:["IS","2","CenterOfCircularShutter"],1612:["IS","1","RadiusOfCircularShutter"],1620:["IS","2-2n","VerticesOfThePolygonalShutter"],1622:["US","1","ShutterPresentationValue"],1623:["US","1","ShutterOverlayGroup"],1624:["US","3","ShutterPresentationColorCIELabValue"],1630:["CS","1","OutlineShapeType"],1631:["FD","1","OutlineLeftVerticalEdge"],1632:["FD","1","OutlineRightVerticalEdge"],1633:["FD","1","OutlineUpperHorizontalEdge"],1634:["FD","1","OutlineLowerHorizontalEdge"],1635:["FD","2","CenterOfCircularOutline"],1636:["FD","1","DiameterOfCircularOutline"],1637:["UL","1","NumberOfPolygonalVertices"],1638:["OF","1","VerticesOfThePolygonalOutline"],1700:["CS","1-3","CollimatorShape"],1702:["IS","1","CollimatorLeftVerticalEdge"],1704:["IS","1","CollimatorRightVerticalEdge"],1706:["IS","1","CollimatorUpperHorizontalEdge"],1708:["IS","1","CollimatorLowerHorizontalEdge"],1710:["IS","2","CenterOfCircularCollimator"],1712:["IS","1","RadiusOfCircularCollimator"],1720:["IS","2-2n","VerticesOfThePolygonalCollimator"],1800:["CS","1","AcquisitionTimeSynchronized"],1801:["SH","1","TimeSource"],1802:["CS","1","TimeDistributionProtocol"],1803:["LO","1","NTPSourceAddress"],2001:["IS","1-n","PageNumberVector"],2002:["SH","1-n","FrameLabelVector"],2003:["DS","1-n","FramePrimaryAngleVector"],2004:["DS","1-n","FrameSecondaryAngleVector"],2005:["DS","1-n","SliceLocationVector"],2006:["SH","1-n","DisplayWindowLabelVector"],2010:["DS","2","NominalScannedPixelSpacing"],2020:["CS","1","DigitizingDeviceTransportDirection"],2030:["DS","1","RotationOfScannedFilm"],2041:["SQ","1","BiopsyTargetSequence"],2042:["UI","1","TargetUID"],2043:["FL","2","LocalizingCursorPosition"],2044:["FL","3","CalculatedTargetPosition"],2045:["SH","1","TargetLabel"],2046:["FL","1","DisplayedZValue"],3100:["CS","1","IVUSAcquisition"],3101:["DS","1","IVUSPullbackRate"],3102:["DS","1","IVUSGatedRate"],3103:["IS","1","IVUSPullbackStartFrameNumber"],3104:["IS","1","IVUSPullbackStopFrameNumber"],3105:["IS","1-n","LesionNumber"],4e3:["LT","1","AcquisitionComments"],5e3:["SH","1-n","OutputPower"],5010:["LO","1-n","TransducerData"],5011:["SQ","1","TransducerIdentificationSequence"],5012:["DS","1","FocusDepth"],5020:["LO","1","ProcessingFunction"],5021:["LO","1","PostprocessingFunction"],5022:["DS","1","MechanicalIndex"],5024:["DS","1","BoneThermalIndex"],5026:["DS","1","CranialThermalIndex"],5027:["DS","1","SoftTissueThermalIndex"],5028:["DS","1","SoftTissueFocusThermalIndex"],5029:["DS","1","SoftTissueSurfaceThermalIndex"],5030:["DS","1","DynamicRange"],5040:["DS","1","TotalGain"],5050:["IS","1","DepthOfScanField"],5100:["CS","1","PatientPosition"],5101:["CS","1","ViewPosition"],5104:["SQ","1","ProjectionEponymousNameCodeSequence"],5210:["DS","6","ImageTransformationMatrix"],5212:["DS","3","ImageTranslationVector"],6e3:["DS","1","Sensitivity"],6011:["SQ","1","SequenceOfUltrasoundRegions"],6012:["US","1","RegionSpatialFormat"],6014:["US","1","RegionDataType"],6016:["UL","1","RegionFlags"],6018:["UL","1","RegionLocationMinX0"],"601A":["UL","1","RegionLocationMinY0"],"601C":["UL","1","RegionLocationMaxX1"],"601E":["UL","1","RegionLocationMaxY1"],6020:["SL","1","ReferencePixelX0"],6022:["SL","1","ReferencePixelY0"],6024:["US","1","PhysicalUnitsXDirection"],6026:["US","1","PhysicalUnitsYDirection"],6028:["FD","1","ReferencePixelPhysicalValueX"],"602A":["FD","1","ReferencePixelPhysicalValueY"],"602C":["FD","1","PhysicalDeltaX"],"602E":["FD","1","PhysicalDeltaY"],6030:["UL","1","TransducerFrequency"],6031:["CS","1","TransducerType"],6032:["UL","1","PulseRepetitionFrequency"],6034:["FD","1","DopplerCorrectionAngle"],6036:["FD","1","SteeringAngle"],6038:["UL","1","DopplerSampleVolumeXPositionRetired"],6039:["SL","1","DopplerSampleVolumeXPosition"],"603A":["UL","1","DopplerSampleVolumeYPositionRetired"],"603B":["SL","1","DopplerSampleVolumeYPosition"],"603C":["UL","1","TMLinePositionX0Retired"],"603D":["SL","1","TMLinePositionX0"],"603E":["UL","1","TMLinePositionY0Retired"],"603F":["SL","1","TMLinePositionY0"],6040:["UL","1","TMLinePositionX1Retired"],6041:["SL","1","TMLinePositionX1"],6042:["UL","1","TMLinePositionY1Retired"],6043:["SL","1","TMLinePositionY1"],6044:["US","1","PixelComponentOrganization"],6046:["UL","1","PixelComponentMask"],6048:["UL","1","PixelComponentRangeStart"],"604A":["UL","1","PixelComponentRangeStop"],"604C":["US","1","PixelComponentPhysicalUnits"],"604E":["US","1","PixelComponentDataType"],6050:["UL","1","NumberOfTableBreakPoints"],6052:["UL","1-n","TableOfXBreakPoints"],6054:["FD","1-n","TableOfYBreakPoints"],6056:["UL","1","NumberOfTableEntries"],6058:["UL","1-n","TableOfPixelValues"],"605A":["FL","1-n","TableOfParameterValues"],6060:["FL","1-n","RWaveTimeVector"],6070:["US","1","ActiveImageAreaOverlayGroup"],7e3:["CS","1","DetectorConditionsNominalFlag"],7001:["DS","1","DetectorTemperature"],7004:["CS","1","DetectorType"],7005:["CS","1","DetectorConfiguration"],7006:["LT","1","DetectorDescription"],7008:["LT","1","DetectorMode"],"700A":["SH","1","DetectorID"],"700C":["DA","1","DateOfLastDetectorCalibration"],"700E":["TM","1","TimeOfLastDetectorCalibration"],7010:["IS","1","ExposuresOnDetectorSinceLastCalibration"],7011:["IS","1","ExposuresOnDetectorSinceManufactured"],7012:["DS","1","DetectorTimeSinceLastExposure"],7014:["DS","1","DetectorActiveTime"],7016:["DS","1","DetectorActivationOffsetFromExposure"],"701A":["DS","2","DetectorBinning"],7020:["DS","2","DetectorElementPhysicalSize"],7022:["DS","2","DetectorElementSpacing"],7024:["CS","1","DetectorActiveShape"],7026:["DS","1-2","DetectorActiveDimensions"],7028:["DS","2","DetectorActiveOrigin"],"702A":["LO","1","DetectorManufacturerName"],"702B":["LO","1","DetectorManufacturerModelName"],7030:["DS","2","FieldOfViewOrigin"],7032:["DS","1","FieldOfViewRotation"],7034:["CS","1","FieldOfViewHorizontalFlip"],7036:["FL","2","PixelDataAreaOriginRelativeToFOV"],7038:["FL","1","PixelDataAreaRotationAngleRelativeToFOV"],7040:["LT","1","GridAbsorbingMaterial"],7041:["LT","1","GridSpacingMaterial"],7042:["DS","1","GridThickness"],7044:["DS","1","GridPitch"],7046:["IS","2","GridAspectRatio"],7048:["DS","1","GridPeriod"],"704C":["DS","1","GridFocalDistance"],7050:["CS","1-n","FilterMaterial"],7052:["DS","1-n","FilterThicknessMinimum"],7054:["DS","1-n","FilterThicknessMaximum"],7056:["FL","1-n","FilterBeamPathLengthMinimum"],7058:["FL","1-n","FilterBeamPathLengthMaximum"],7060:["CS","1","ExposureControlMode"],7062:["LT","1","ExposureControlModeDescription"],7064:["CS","1","ExposureStatus"],7065:["DS","1","PhototimerSetting"],8150:["DS","1","ExposureTimeInuS"],8151:["DS","1","XRayTubeCurrentInuA"],9004:["CS","1","ContentQualification"],9005:["SH","1","PulseSequenceName"],9006:["SQ","1","MRImagingModifierSequence"],9008:["CS","1","EchoPulseSequence"],9009:["CS","1","InversionRecovery"],9010:["CS","1","FlowCompensation"],9011:["CS","1","MultipleSpinEcho"],9012:["CS","1","MultiPlanarExcitation"],9014:["CS","1","PhaseContrast"],9015:["CS","1","TimeOfFlightContrast"],9016:["CS","1","Spoiling"],9017:["CS","1","SteadyStatePulseSequence"],9018:["CS","1","EchoPlanarPulseSequence"],9019:["FD","1","TagAngleFirstAxis"],9020:["CS","1","MagnetizationTransfer"],9021:["CS","1","T2Preparation"],9022:["CS","1","BloodSignalNulling"],9024:["CS","1","SaturationRecovery"],9025:["CS","1","SpectrallySelectedSuppression"],9026:["CS","1","SpectrallySelectedExcitation"],9027:["CS","1","SpatialPresaturation"],9028:["CS","1","Tagging"],9029:["CS","1","OversamplingPhase"],9030:["FD","1","TagSpacingFirstDimension"],9032:["CS","1","GeometryOfKSpaceTraversal"],9033:["CS","1","SegmentedKSpaceTraversal"],9034:["CS","1","RectilinearPhaseEncodeReordering"],9035:["FD","1","TagThickness"],9036:["CS","1","PartialFourierDirection"],9037:["CS","1","CardiacSynchronizationTechnique"],9041:["LO","1","ReceiveCoilManufacturerName"],9042:["SQ","1","MRReceiveCoilSequence"],9043:["CS","1","ReceiveCoilType"],9044:["CS","1","QuadratureReceiveCoil"],9045:["SQ","1","MultiCoilDefinitionSequence"],9046:["LO","1","MultiCoilConfiguration"],9047:["SH","1","MultiCoilElementName"],9048:["CS","1","MultiCoilElementUsed"],9049:["SQ","1","MRTransmitCoilSequence"],9050:["LO","1","TransmitCoilManufacturerName"],9051:["CS","1","TransmitCoilType"],9052:["FD","1-2","SpectralWidth"],9053:["FD","1-2","ChemicalShiftReference"],9054:["CS","1","VolumeLocalizationTechnique"],9058:["US","1","MRAcquisitionFrequencyEncodingSteps"],9059:["CS","1","Decoupling"],9060:["CS","1-2","DecoupledNucleus"],9061:["FD","1-2","DecouplingFrequency"],9062:["CS","1","DecouplingMethod"],9063:["FD","1-2","DecouplingChemicalShiftReference"],9064:["CS","1","KSpaceFiltering"],9065:["CS","1-2","TimeDomainFiltering"],9066:["US","1-2","NumberOfZeroFills"],9067:["CS","1","BaselineCorrection"],9069:["FD","1","ParallelReductionFactorInPlane"],9070:["FD","1","CardiacRRIntervalSpecified"],9073:["FD","1","AcquisitionDuration"],9074:["DT","1","FrameAcquisitionDateTime"],9075:["CS","1","DiffusionDirectionality"],9076:["SQ","1","DiffusionGradientDirectionSequence"],9077:["CS","1","ParallelAcquisition"],9078:["CS","1","ParallelAcquisitionTechnique"],9079:["FD","1-n","InversionTimes"],9080:["ST","1","MetaboliteMapDescription"],9081:["CS","1","PartialFourier"],9082:["FD","1","EffectiveEchoTime"],9083:["SQ","1","MetaboliteMapCodeSequence"],9084:["SQ","1","ChemicalShiftSequence"],9085:["CS","1","CardiacSignalSource"],9087:["FD","1","DiffusionBValue"],9089:["FD","3","DiffusionGradientOrientation"],9090:["FD","3","VelocityEncodingDirection"],9091:["FD","1","VelocityEncodingMinimumValue"],9092:["SQ","1","VelocityEncodingAcquisitionSequence"],9093:["US","1","NumberOfKSpaceTrajectories"],9094:["CS","1","CoverageOfKSpace"],9095:["UL","1","SpectroscopyAcquisitionPhaseRows"],9096:["FD","1","ParallelReductionFactorInPlaneRetired"],9098:["FD","1-2","TransmitterFrequency"],9100:["CS","1-2","ResonantNucleus"],9101:["CS","1","FrequencyCorrection"],9103:["SQ","1","MRSpectroscopyFOVGeometrySequence"],9104:["FD","1","SlabThickness"],9105:["FD","3","SlabOrientation"],9106:["FD","3","MidSlabPosition"],9107:["SQ","1","MRSpatialSaturationSequence"],9112:["SQ","1","MRTimingAndRelatedParametersSequence"],9114:["SQ","1","MREchoSequence"],9115:["SQ","1","MRModifierSequence"],9117:["SQ","1","MRDiffusionSequence"],9118:["SQ","1","CardiacSynchronizationSequence"],9119:["SQ","1","MRAveragesSequence"],9125:["SQ","1","MRFOVGeometrySequence"],9126:["SQ","1","VolumeLocalizationSequence"],9127:["UL","1","SpectroscopyAcquisitionDataColumns"],9147:["CS","1","DiffusionAnisotropyType"],9151:["DT","1","FrameReferenceDateTime"],9152:["SQ","1","MRMetaboliteMapSequence"],9155:["FD","1","ParallelReductionFactorOutOfPlane"],9159:["UL","1","SpectroscopyAcquisitionOutOfPlanePhaseSteps"],9166:["CS","1","BulkMotionStatus"],9168:["FD","1","ParallelReductionFactorSecondInPlane"],9169:["CS","1","CardiacBeatRejectionTechnique"],9170:["CS","1","RespiratoryMotionCompensationTechnique"],9171:["CS","1","RespiratorySignalSource"],9172:["CS","1","BulkMotionCompensationTechnique"],9173:["CS","1","BulkMotionSignalSource"],9174:["CS","1","ApplicableSafetyStandardAgency"],9175:["LO","1","ApplicableSafetyStandardDescription"],9176:["SQ","1","OperatingModeSequence"],9177:["CS","1","OperatingModeType"],9178:["CS","1","OperatingMode"],9179:["CS","1","SpecificAbsorptionRateDefinition"],9180:["CS","1","GradientOutputType"],9181:["FD","1","SpecificAbsorptionRateValue"],9182:["FD","1","GradientOutput"],9183:["CS","1","FlowCompensationDirection"],9184:["FD","1","TaggingDelay"],9185:["ST","1","RespiratoryMotionCompensationTechniqueDescription"],9186:["SH","1","RespiratorySignalSourceID"],9195:["FD","1","ChemicalShiftMinimumIntegrationLimitInHz"],9196:["FD","1","ChemicalShiftMaximumIntegrationLimitInHz"],9197:["SQ","1","MRVelocityEncodingSequence"],9198:["CS","1","FirstOrderPhaseCorrection"],9199:["CS","1","WaterReferencedPhaseCorrection"],9200:["CS","1","MRSpectroscopyAcquisitionType"],9214:["CS","1","RespiratoryCyclePosition"],9217:["FD","1","VelocityEncodingMaximumValue"],9218:["FD","1","TagSpacingSecondDimension"],9219:["SS","1","TagAngleSecondAxis"],9220:["FD","1","FrameAcquisitionDuration"],9226:["SQ","1","MRImageFrameTypeSequence"],9227:["SQ","1","MRSpectroscopyFrameTypeSequence"],9231:["US","1","MRAcquisitionPhaseEncodingStepsInPlane"],9232:["US","1","MRAcquisitionPhaseEncodingStepsOutOfPlane"],9234:["UL","1","SpectroscopyAcquisitionPhaseColumns"],9236:["CS","1","CardiacCyclePosition"],9239:["SQ","1","SpecificAbsorptionRateSequence"],9240:["US","1","RFEchoTrainLength"],9241:["US","1","GradientEchoTrainLength"],9250:["CS","1","ArterialSpinLabelingContrast"],9251:["SQ","1","MRArterialSpinLabelingSequence"],9252:["LO","1","ASLTechniqueDescription"],9253:["US","1","ASLSlabNumber"],9254:["FD","1","ASLSlabThickness"],9255:["FD","3","ASLSlabOrientation"],9256:["FD","3","ASLMidSlabPosition"],9257:["CS","1","ASLContext"],9258:["UL","1","ASLPulseTrainDuration"],9259:["CS","1","ASLCrusherFlag"],"925A":["FD","1","ASLCrusherFlowLimit"],"925B":["LO","1","ASLCrusherDescription"],"925C":["CS","1","ASLBolusCutoffFlag"],"925D":["SQ","1","ASLBolusCutoffTimingSequence"],"925E":["LO","1","ASLBolusCutoffTechnique"],"925F":["UL","1","ASLBolusCutoffDelayTime"],9260:["SQ","1","ASLSlabSequence"],9295:["FD","1","ChemicalShiftMinimumIntegrationLimitInppm"],9296:["FD","1","ChemicalShiftMaximumIntegrationLimitInppm"],9297:["CS","1","WaterReferenceAcquisition"],9298:["IS","1","EchoPeakPosition"],9301:["SQ","1","CTAcquisitionTypeSequence"],9302:["CS","1","AcquisitionType"],9303:["FD","1","TubeAngle"],9304:["SQ","1","CTAcquisitionDetailsSequence"],9305:["FD","1","RevolutionTime"],9306:["FD","1","SingleCollimationWidth"],9307:["FD","1","TotalCollimationWidth"],9308:["SQ","1","CTTableDynamicsSequence"],9309:["FD","1","TableSpeed"],9310:["FD","1","TableFeedPerRotation"],9311:["FD","1","SpiralPitchFactor"],9312:["SQ","1","CTGeometrySequence"],9313:["FD","3","DataCollectionCenterPatient"],9314:["SQ","1","CTReconstructionSequence"],9315:["CS","1","ReconstructionAlgorithm"],9316:["CS","1","ConvolutionKernelGroup"],9317:["FD","2","ReconstructionFieldOfView"],9318:["FD","3","ReconstructionTargetCenterPatient"],9319:["FD","1","ReconstructionAngle"],9320:["SH","1","ImageFilter"],9321:["SQ","1","CTExposureSequence"],9322:["FD","2","ReconstructionPixelSpacing"],9323:["CS","1-n","ExposureModulationType"],9324:["FD","1","EstimatedDoseSaving"],9325:["SQ","1","CTXRayDetailsSequence"],9326:["SQ","1","CTPositionSequence"],9327:["FD","1","TablePosition"],9328:["FD","1","ExposureTimeInms"],9329:["SQ","1","CTImageFrameTypeSequence"],9330:["FD","1","XRayTubeCurrentInmA"],9332:["FD","1","ExposureInmAs"],9333:["CS","1","ConstantVolumeFlag"],9334:["CS","1","FluoroscopyFlag"],9335:["FD","1","DistanceSourceToDataCollectionCenter"],9337:["US","1","ContrastBolusAgentNumber"],9338:["SQ","1","ContrastBolusIngredientCodeSequence"],9340:["SQ","1","ContrastAdministrationProfileSequence"],9341:["SQ","1","ContrastBolusUsageSequence"],9342:["CS","1","ContrastBolusAgentAdministered"],9343:["CS","1","ContrastBolusAgentDetected"],9344:["CS","1","ContrastBolusAgentPhase"],9345:["FD","1","CTDIvol"],9346:["SQ","1","CTDIPhantomTypeCodeSequence"],9351:["FL","1","CalciumScoringMassFactorPatient"],9352:["FL","3","CalciumScoringMassFactorDevice"],9353:["FL","1","EnergyWeightingFactor"],9360:["SQ","1","CTAdditionalXRaySourceSequence"],9361:["CS","1","MultienergyCTAcquisition"],9362:["SQ","1","MultienergyCTAcquisitionSequence"],9363:["SQ","1","MultienergyCTProcessingSequence"],9364:["SQ","1","MultienergyCTCharacteristicsSequence"],9365:["SQ","1","MultienergyCTXRaySourceSequence"],9366:["US","1","XRaySourceIndex"],9367:["UC","1","XRaySourceID"],9368:["CS","1","MultienergySourceTechnique"],9369:["DT","1","SourceStartDateTime"],"936A":["DT","1","SourceEndDateTime"],"936B":["US","1","SwitchingPhaseNumber"],"936C":["DS","1","SwitchingPhaseNominalDuration"],"936D":["DS","1","SwitchingPhaseTransitionDuration"],"936E":["DS","1","EffectiveBinEnergy"],"936F":["SQ","1","MultienergyCTXRayDetectorSequence"],9370:["US","1","XRayDetectorIndex"],9371:["UC","1","XRayDetectorID"],9372:["CS","1","MultienergyDetectorType"],9373:["ST","1","XRayDetectorLabel"],9374:["DS","1","NominalMaxEnergy"],9375:["DS","1","NominalMinEnergy"],9376:["US","1-n","ReferencedXRayDetectorIndex"],9377:["US","1-n","ReferencedXRaySourceIndex"],9378:["US","1-n","ReferencedPathIndex"],9379:["SQ","1","MultienergyCTPathSequence"],"937A":["US","1","MultienergyCTPathIndex"],"937B":["UT","1","MultienergyAcquisitionDescription"],"937C":["FD","1","MonoenergeticEnergyEquivalent"],"937D":["SQ","1","MaterialCodeSequence"],"937E":["CS","1","DecompositionMethod"],"937F":["UT","1","DecompositionDescription"],9380:["SQ","1","DecompositionAlgorithmIdentificationSequence"],9381:["SQ","1","DecompositionMaterialSequence"],9382:["SQ","1","MaterialAttenuationSequence"],9383:["DS","1","PhotonEnergy"],9384:["DS","1","XRayMassAttenuationCoefficient"],9401:["SQ","1","ProjectionPixelCalibrationSequence"],9402:["FL","1","DistanceSourceToIsocenter"],9403:["FL","1","DistanceObjectToTableTop"],9404:["FL","2","ObjectPixelSpacingInCenterOfBeam"],9405:["SQ","1","PositionerPositionSequence"],9406:["SQ","1","TablePositionSequence"],9407:["SQ","1","CollimatorShapeSequence"],9410:["CS","1","PlanesInAcquisition"],9412:["SQ","1","XAXRFFrameCharacteristicsSequence"],9417:["SQ","1","FrameAcquisitionSequence"],9420:["CS","1","XRayReceptorType"],9423:["LO","1","AcquisitionProtocolName"],9424:["LT","1","AcquisitionProtocolDescription"],9425:["CS","1","ContrastBolusIngredientOpaque"],9426:["FL","1","DistanceReceptorPlaneToDetectorHousing"],9427:["CS","1","IntensifierActiveShape"],9428:["FL","1-2","IntensifierActiveDimensions"],9429:["FL","2","PhysicalDetectorSize"],9430:["FL","2","PositionOfIsocenterProjection"],9432:["SQ","1","FieldOfViewSequence"],9433:["LO","1","FieldOfViewDescription"],9434:["SQ","1","ExposureControlSensingRegionsSequence"],9435:["CS","1","ExposureControlSensingRegionShape"],9436:["SS","1","ExposureControlSensingRegionLeftVerticalEdge"],9437:["SS","1","ExposureControlSensingRegionRightVerticalEdge"],9438:["SS","1","ExposureControlSensingRegionUpperHorizontalEdge"],9439:["SS","1","ExposureControlSensingRegionLowerHorizontalEdge"],9440:["SS","2","CenterOfCircularExposureControlSensingRegion"],9441:["US","1","RadiusOfCircularExposureControlSensingRegion"],9442:["SS","2-n","VerticesOfThePolygonalExposureControlSensingRegion"],9445:["","",""],9447:["FL","1","ColumnAngulationPatient"],9449:["FL","1","BeamAngle"],9451:["SQ","1","FrameDetectorParametersSequence"],9452:["FL","1","CalculatedAnatomyThickness"],9455:["SQ","1","CalibrationSequence"],9456:["SQ","1","ObjectThicknessSequence"],9457:["CS","1","PlaneIdentification"],9461:["FL","1-2","FieldOfViewDimensionsInFloat"],9462:["SQ","1","IsocenterReferenceSystemSequence"],9463:["FL","1","PositionerIsocenterPrimaryAngle"],9464:["FL","1","PositionerIsocenterSecondaryAngle"],9465:["FL","1","PositionerIsocenterDetectorRotationAngle"],9466:["FL","1","TableXPositionToIsocenter"],9467:["FL","1","TableYPositionToIsocenter"],9468:["FL","1","TableZPositionToIsocenter"],9469:["FL","1","TableHorizontalRotationAngle"],9470:["FL","1","TableHeadTiltAngle"],9471:["FL","1","TableCradleTiltAngle"],9472:["SQ","1","FrameDisplayShutterSequence"],9473:["FL","1","AcquiredImageAreaDoseProduct"],9474:["CS","1","CArmPositionerTabletopRelationship"],9476:["SQ","1","XRayGeometrySequence"],9477:["SQ","1","IrradiationEventIdentificationSequence"],9504:["SQ","1","XRay3DFrameTypeSequence"],9506:["SQ","1","ContributingSourcesSequence"],9507:["SQ","1","XRay3DAcquisitionSequence"],9508:["FL","1","PrimaryPositionerScanArc"],9509:["FL","1","SecondaryPositionerScanArc"],9510:["FL","1","PrimaryPositionerScanStartAngle"],9511:["FL","1","SecondaryPositionerScanStartAngle"],9514:["FL","1","PrimaryPositionerIncrement"],9515:["FL","1","SecondaryPositionerIncrement"],9516:["DT","1","StartAcquisitionDateTime"],9517:["DT","1","EndAcquisitionDateTime"],9518:["SS","1","PrimaryPositionerIncrementSign"],9519:["SS","1","SecondaryPositionerIncrementSign"],9524:["LO","1","ApplicationName"],9525:["LO","1","ApplicationVersion"],9526:["LO","1","ApplicationManufacturer"],9527:["CS","1","AlgorithmType"],9528:["LO","1","AlgorithmDescription"],9530:["SQ","1","XRay3DReconstructionSequence"],9531:["LO","1","ReconstructionDescription"],9538:["SQ","1","PerProjectionAcquisitionSequence"],9541:["SQ","1","DetectorPositionSequence"],9542:["SQ","1","XRayAcquisitionDoseSequence"],9543:["FD","1","XRaySourceIsocenterPrimaryAngle"],9544:["FD","1","XRaySourceIsocenterSecondaryAngle"],9545:["FD","1","BreastSupportIsocenterPrimaryAngle"],9546:["FD","1","BreastSupportIsocenterSecondaryAngle"],9547:["FD","1","BreastSupportXPositionToIsocenter"],9548:["FD","1","BreastSupportYPositionToIsocenter"],9549:["FD","1","BreastSupportZPositionToIsocenter"],9550:["FD","1","DetectorIsocenterPrimaryAngle"],9551:["FD","1","DetectorIsocenterSecondaryAngle"],9552:["FD","1","DetectorXPositionToIsocenter"],9553:["FD","1","DetectorYPositionToIsocenter"],9554:["FD","1","DetectorZPositionToIsocenter"],9555:["SQ","1","XRayGridSequence"],9556:["SQ","1","XRayFilterSequence"],9557:["FD","3","DetectorActiveAreaTLHCPosition"],9558:["FD","6","DetectorActiveAreaOrientation"],9559:["CS","1","PositionerPrimaryAngleDirection"],9601:["SQ","1","DiffusionBMatrixSequence"],9602:["FD","1","DiffusionBValueXX"],9603:["FD","1","DiffusionBValueXY"],9604:["FD","1","DiffusionBValueXZ"],9605:["FD","1","DiffusionBValueYY"],9606:["FD","1","DiffusionBValueYZ"],9607:["FD","1","DiffusionBValueZZ"],9621:["SQ","1","FunctionalMRSequence"],9622:["CS","1","FunctionalSettlingPhaseFramesPresent"],9623:["DT","1","FunctionalSyncPulse"],9624:["CS","1","SettlingPhaseFrame"],9701:["DT","1","DecayCorrectionDateTime"],9715:["FD","1","StartDensityThreshold"],9716:["FD","1","StartRelativeDensityDifferenceThreshold"],9717:["FD","1","StartCardiacTriggerCountThreshold"],9718:["FD","1","StartRespiratoryTriggerCountThreshold"],9719:["FD","1","TerminationCountsThreshold"],9720:["FD","1","TerminationDensityThreshold"],9721:["FD","1","TerminationRelativeDensityThreshold"],9722:["FD","1","TerminationTimeThreshold"],9723:["FD","1","TerminationCardiacTriggerCountThreshold"],9724:["FD","1","TerminationRespiratoryTriggerCountThreshold"],9725:["CS","1","DetectorGeometry"],9726:["FD","1","TransverseDetectorSeparation"],9727:["FD","1","AxialDetectorDimension"],9729:["US","1","RadiopharmaceuticalAgentNumber"],9732:["SQ","1","PETFrameAcquisitionSequence"],9733:["SQ","1","PETDetectorMotionDetailsSequence"],9734:["SQ","1","PETTableDynamicsSequence"],9735:["SQ","1","PETPositionSequence"],9736:["SQ","1","PETFrameCorrectionFactorsSequence"],9737:["SQ","1","RadiopharmaceuticalUsageSequence"],9738:["CS","1","AttenuationCorrectionSource"],9739:["US","1","NumberOfIterations"],9740:["US","1","NumberOfSubsets"],9749:["SQ","1","PETReconstructionSequence"],9751:["SQ","1","PETFrameTypeSequence"],9755:["CS","1","TimeOfFlightInformationUsed"],9756:["CS","1","ReconstructionType"],9758:["CS","1","DecayCorrected"],9759:["CS","1","AttenuationCorrected"],9760:["CS","1","ScatterCorrected"],9761:["CS","1","DeadTimeCorrected"],9762:["CS","1","GantryMotionCorrected"],9763:["CS","1","PatientMotionCorrected"],9764:["CS","1","CountLossNormalizationCorrected"],9765:["CS","1","RandomsCorrected"],9766:["CS","1","NonUniformRadialSamplingCorrected"],9767:["CS","1","SensitivityCalibrated"],9768:["CS","1","DetectorNormalizationCorrection"],9769:["CS","1","IterativeReconstructionMethod"],9770:["CS","1","AttenuationCorrectionTemporalRelationship"],9771:["SQ","1","PatientPhysiologicalStateSequence"],9772:["SQ","1","PatientPhysiologicalStateCodeSequence"],9801:["FD","1-n","DepthsOfFocus"],9803:["SQ","1","ExcludedIntervalsSequence"],9804:["DT","1","ExclusionStartDateTime"],9805:["FD","1","ExclusionDuration"],9806:["SQ","1","USImageDescriptionSequence"],9807:["SQ","1","ImageDataTypeSequence"],9808:["CS","1","DataType"],9809:["SQ","1","TransducerScanPatternCodeSequence"],"980B":["CS","1","AliasedDataType"],"980C":["CS","1","PositionMeasuringDeviceUsed"],"980D":["SQ","1","TransducerGeometryCodeSequence"],"980E":["SQ","1","TransducerBeamSteeringCodeSequence"],"980F":["SQ","1","TransducerApplicationCodeSequence"],9810:["xs","1","ZeroVelocityPixelValue"],9900:["LO","1","ReferenceLocationLabel"],9901:["UT","1","ReferenceLocationDescription"],9902:["SQ","1","ReferenceBasisCodeSequence"],9903:["SQ","1","ReferenceGeometryCodeSequence"],9904:["DS","1","OffsetDistance"],9905:["CS","1","OffsetDirection"],9906:["SQ","1","PotentialScheduledProtocolCodeSequence"],9907:["SQ","1","PotentialRequestedProcedureCodeSequence"],9908:["UC","1-n","PotentialReasonsForProcedure"],9909:["SQ","1","PotentialReasonsForProcedureCodeSequence"],"990A":["UC","1-n","PotentialDiagnosticTasks"],"990B":["SQ","1","ContraindicationsCodeSequence"],"990C":["SQ","1","ReferencedDefinedProtocolSequence"],"990D":["SQ","1","ReferencedPerformedProtocolSequence"],"990E":["SQ","1","PredecessorProtocolSequence"],"990F":["UT","1","ProtocolPlanningInformation"],9910:["UT","1","ProtocolDesignRationale"],9911:["SQ","1","PatientSpecificationSequence"],9912:["SQ","1","ModelSpecificationSequence"],9913:["SQ","1","ParametersSpecificationSequence"],9914:["SQ","1","InstructionSequence"],9915:["US","1","InstructionIndex"],9916:["LO","1","InstructionText"],9917:["UT","1","InstructionDescription"],9918:["CS","1","InstructionPerformedFlag"],9919:["DT","1","InstructionPerformedDateTime"],"991A":["UT","1","InstructionPerformanceComment"],"991B":["SQ","1","PatientPositioningInstructionSequence"],"991C":["SQ","1","PositioningMethodCodeSequence"],"991D":["SQ","1","PositioningLandmarkSequence"],"991E":["UI","1","TargetFrameOfReferenceUID"],"991F":["SQ","1","AcquisitionProtocolElementSpecificationSequence"],9920:["SQ","1","AcquisitionProtocolElementSequence"],9921:["US","1","ProtocolElementNumber"],9922:["LO","1","ProtocolElementName"],9923:["UT","1","ProtocolElementCharacteristicsSummary"],9924:["UT","1","ProtocolElementPurpose"],9930:["CS","1","AcquisitionMotion"],9931:["SQ","1","AcquisitionStartLocationSequence"],9932:["SQ","1","AcquisitionEndLocationSequence"],9933:["SQ","1","ReconstructionProtocolElementSpecificationSequence"],9934:["SQ","1","ReconstructionProtocolElementSequence"],9935:["SQ","1","StorageProtocolElementSpecificationSequence"],9936:["SQ","1","StorageProtocolElementSequence"],9937:["LO","1","RequestedSeriesDescription"],9938:["US","1-n","SourceAcquisitionProtocolElementNumber"],9939:["US","1-n","SourceAcquisitionBeamNumber"],"993A":["US","1-n","SourceReconstructionProtocolElementNumber"],"993B":["SQ","1","ReconstructionStartLocationSequence"],"993C":["SQ","1","ReconstructionEndLocationSequence"],"993D":["SQ","1","ReconstructionAlgorithmSequence"],"993E":["SQ","1","ReconstructionTargetCenterLocationSequence"],9941:["UT","1","ImageFilterDescription"],9942:["FD","1","CTDIvolNotificationTrigger"],9943:["FD","1","DLPNotificationTrigger"],9944:["CS","1","AutoKVPSelectionType"],9945:["FD","1","AutoKVPUpperBound"],9946:["FD","1","AutoKVPLowerBound"],9947:["CS","1","ProtocolDefinedPatientPosition"],A001:["SQ","1","ContributingEquipmentSequence"],A002:["DT","1","ContributionDateTime"],A003:["ST","1","ContributionDescription"]},"0020":{"0000":["UL","1","GenericGroupLength"],"000D":["UI","1","StudyInstanceUID"],"000E":["UI","1","SeriesInstanceUID"],"0010":["SH","1","StudyID"],"0011":["IS","1","SeriesNumber"],"0012":["IS","1","AcquisitionNumber"],"0013":["IS","1","InstanceNumber"],"0014":["IS","1","IsotopeNumber"],"0015":["IS","1","PhaseNumber"],"0016":["IS","1","IntervalNumber"],"0017":["IS","1","TimeSlotNumber"],"0018":["IS","1","AngleNumber"],"0019":["IS","1","ItemNumber"],"0020":["CS","2","PatientOrientation"],"0022":["IS","1","OverlayNumber"],"0024":["IS","1","CurveNumber"],"0026":["IS","1","LUTNumber"],"0030":["DS","3","ImagePosition"],"0032":["DS","3","ImagePositionPatient"],"0035":["DS","6","ImageOrientation"],"0037":["DS","6","ImageOrientationPatient"],"0050":["DS","1","Location"],"0052":["UI","1","FrameOfReferenceUID"],"0060":["CS","1","Laterality"],"0062":["CS","1","ImageLaterality"],"0070":["LO","1","ImageGeometryType"],"0080":["CS","1-n","MaskingImage"],"00AA":["IS","1","ReportNumber"],"0100":["IS","1","TemporalPositionIdentifier"],"0105":["IS","1","NumberOfTemporalPositions"],"0110":["DS","1","TemporalResolution"],"0200":["UI","1","SynchronizationFrameOfReferenceUID"],"0242":["UI","1","SOPInstanceUIDOfConcatenationSource"],1e3:["IS","1","SeriesInStudy"],1001:["IS","1","AcquisitionsInSeries"],1002:["IS","1","ImagesInAcquisition"],1003:["IS","1","ImagesInSeries"],1004:["IS","1","AcquisitionsInStudy"],1005:["IS","1","ImagesInStudy"],1020:["LO","1-n","Reference"],"103F":["LO","1","TargetPositionReferenceIndicator"],1040:["LO","1","PositionReferenceIndicator"],1041:["DS","1","SliceLocation"],1070:["IS","1-n","OtherStudyNumbers"],1200:["IS","1","NumberOfPatientRelatedStudies"],1202:["IS","1","NumberOfPatientRelatedSeries"],1204:["IS","1","NumberOfPatientRelatedInstances"],1206:["IS","1","NumberOfStudyRelatedSeries"],1208:["IS","1","NumberOfStudyRelatedInstances"],1209:["IS","1","NumberOfSeriesRelatedInstances"],3100:["CS","1-n","SourceImageIDs"],3401:["CS","1","ModifyingDeviceID"],3402:["CS","1","ModifiedImageID"],3403:["DA","1","ModifiedImageDate"],3404:["LO","1","ModifyingDeviceManufacturer"],3405:["TM","1","ModifiedImageTime"],3406:["LO","1","ModifiedImageDescription"],4e3:["LT","1","ImageComments"],5e3:["AT","1-n","OriginalImageIdentification"],5002:["LO","1-n","OriginalImageIdentificationNomenclature"],9056:["SH","1","StackID"],9057:["UL","1","InStackPositionNumber"],9071:["SQ","1","FrameAnatomySequence"],9072:["CS","1","FrameLaterality"],9111:["SQ","1","FrameContentSequence"],9113:["SQ","1","PlanePositionSequence"],9116:["SQ","1","PlaneOrientationSequence"],9128:["UL","1","TemporalPositionIndex"],9153:["FD","1","NominalCardiacTriggerDelayTime"],9154:["FL","1","NominalCardiacTriggerTimePriorToRPeak"],9155:["FL","1","ActualCardiacTriggerTimePriorToRPeak"],9156:["US","1","FrameAcquisitionNumber"],9157:["UL","1-n","DimensionIndexValues"],9158:["LT","1","FrameComments"],9161:["UI","1","ConcatenationUID"],9162:["US","1","InConcatenationNumber"],9163:["US","1","InConcatenationTotalNumber"],9164:["UI","1","DimensionOrganizationUID"],9165:["AT","1","DimensionIndexPointer"],9167:["AT","1","FunctionalGroupPointer"],9170:["SQ","1","UnassignedSharedConvertedAttributesSequence"],9171:["SQ","1","UnassignedPerFrameConvertedAttributesSequence"],9172:["SQ","1","ConversionSourceAttributesSequence"],9213:["LO","1","DimensionIndexPrivateCreator"],9221:["SQ","1","DimensionOrganizationSequence"],9222:["SQ","1","DimensionIndexSequence"],9228:["UL","1","ConcatenationFrameOffsetNumber"],9238:["LO","1","FunctionalGroupPrivateCreator"],9241:["FL","1","NominalPercentageOfCardiacPhase"],9245:["FL","1","NominalPercentageOfRespiratoryPhase"],9246:["FL","1","StartingRespiratoryAmplitude"],9247:["CS","1","StartingRespiratoryPhase"],9248:["FL","1","EndingRespiratoryAmplitude"],9249:["CS","1","EndingRespiratoryPhase"],9250:["CS","1","RespiratoryTriggerType"],9251:["FD","1","RRIntervalTimeNominal"],9252:["FD","1","ActualCardiacTriggerDelayTime"],9253:["SQ","1","RespiratorySynchronizationSequence"],9254:["FD","1","RespiratoryIntervalTime"],9255:["FD","1","NominalRespiratoryTriggerDelayTime"],9256:["FD","1","RespiratoryTriggerDelayThreshold"],9257:["FD","1","ActualRespiratoryTriggerDelayTime"],9301:["FD","3","ImagePositionVolume"],9302:["FD","6","ImageOrientationVolume"],9307:["CS","1","UltrasoundAcquisitionGeometry"],9308:["FD","3","ApexPosition"],9309:["FD","16","VolumeToTransducerMappingMatrix"],"930A":["FD","16","VolumeToTableMappingMatrix"],"930B":["CS","1","VolumeToTransducerRelationship"],"930C":["CS","1","PatientFrameOfReferenceSource"],"930D":["FD","1","TemporalPositionTimeOffset"],"930E":["SQ","1","PlanePositionVolumeSequence"],"930F":["SQ","1","PlaneOrientationVolumeSequence"],9310:["SQ","1","TemporalPositionSequence"],9311:["CS","1","DimensionOrganizationType"],9312:["UI","1","VolumeFrameOfReferenceUID"],9313:["UI","1","TableFrameOfReferenceUID"],9421:["LO","1","DimensionDescriptionLabel"],9450:["SQ","1","PatientOrientationInFrameSequence"],9453:["LO","1","FrameLabel"],9518:["US","1-n","AcquisitionIndex"],9529:["SQ","1","ContributingSOPInstancesReferenceSequence"],9536:["US","1","ReconstructionIndex"]},"0022":{"0000":["UL","1","GenericGroupLength"],"0001":["US","1","LightPathFilterPassThroughWavelength"],"0002":["US","2","LightPathFilterPassBand"],"0003":["US","1","ImagePathFilterPassThroughWavelength"],"0004":["US","2","ImagePathFilterPassBand"],"0005":["CS","1","PatientEyeMovementCommanded"],"0006":["SQ","1","PatientEyeMovementCommandCodeSequence"],"0007":["FL","1","SphericalLensPower"],"0008":["FL","1","CylinderLensPower"],"0009":["FL","1","CylinderAxis"],"000A":["FL","1","EmmetropicMagnification"],"000B":["FL","1","IntraOcularPressure"],"000C":["FL","1","HorizontalFieldOfView"],"000D":["CS","1","PupilDilated"],"000E":["FL","1","DegreeOfDilation"],"0010":["FL","1","StereoBaselineAngle"],"0011":["FL","1","StereoBaselineDisplacement"],"0012":["FL","1","StereoHorizontalPixelOffset"],"0013":["FL","1","StereoVerticalPixelOffset"],"0014":["FL","1","StereoRotation"],"0015":["SQ","1","AcquisitionDeviceTypeCodeSequence"],"0016":["SQ","1","IlluminationTypeCodeSequence"],"0017":["SQ","1","LightPathFilterTypeStackCodeSequence"],"0018":["SQ","1","ImagePathFilterTypeStackCodeSequence"],"0019":["SQ","1","LensesCodeSequence"],"001A":["SQ","1","ChannelDescriptionCodeSequence"],"001B":["SQ","1","RefractiveStateSequence"],"001C":["SQ","1","MydriaticAgentCodeSequence"],"001D":["SQ","1","RelativeImagePositionCodeSequence"],"001E":["FL","1","CameraAngleOfView"],"0020":["SQ","1","StereoPairsSequence"],"0021":["SQ","1","LeftImageSequence"],"0022":["SQ","1","RightImageSequence"],"0028":["CS","1","StereoPairsPresent"],"0030":["FL","1","AxialLengthOfTheEye"],"0031":["SQ","1","OphthalmicFrameLocationSequence"],"0032":["FL","2-2n","ReferenceCoordinates"],"0035":["FL","1","DepthSpatialResolution"],"0036":["FL","1","MaximumDepthDistortion"],"0037":["FL","1","AlongScanSpatialResolution"],"0038":["FL","1","MaximumAlongScanDistortion"],"0039":["CS","1","OphthalmicImageOrientation"],"0041":["FL","1","DepthOfTransverseImage"],"0042":["SQ","1","MydriaticAgentConcentrationUnitsSequence"],"0048":["FL","1","AcrossScanSpatialResolution"],"0049":["FL","1","MaximumAcrossScanDistortion"],"004E":["DS","1","MydriaticAgentConcentration"],"0055":["FL","1","IlluminationWaveLength"],"0056":["FL","1","IlluminationPower"],"0057":["FL","1","IlluminationBandwidth"],"0058":["SQ","1","MydriaticAgentSequence"],1007:["SQ","1","OphthalmicAxialMeasurementsRightEyeSequence"],1008:["SQ","1","OphthalmicAxialMeasurementsLeftEyeSequence"],1009:["CS","1","OphthalmicAxialMeasurementsDeviceType"],1010:["CS","1","OphthalmicAxialLengthMeasurementsType"],1012:["SQ","1","OphthalmicAxialLengthSequence"],1019:["FL","1","OphthalmicAxialLength"],1024:["SQ","1","LensStatusCodeSequence"],1025:["SQ","1","VitreousStatusCodeSequence"],1028:["SQ","1","IOLFormulaCodeSequence"],1029:["LO","1","IOLFormulaDetail"],1033:["FL","1","KeratometerIndex"],1035:["SQ","1","SourceOfOphthalmicAxialLengthCodeSequence"],1036:["SQ","1","SourceOfCornealSizeDataCodeSequence"],1037:["FL","1","TargetRefraction"],1039:["CS","1","RefractiveProcedureOccurred"],1040:["SQ","1","RefractiveSurgeryTypeCodeSequence"],1044:["SQ","1","OphthalmicUltrasoundMethodCodeSequence"],1045:["SQ","1","SurgicallyInducedAstigmatismSequence"],1046:["CS","1","TypeOfOpticalCorrection"],1047:["SQ","1","ToricIOLPowerSequence"],1048:["SQ","1","PredictedToricErrorSequence"],1049:["CS","1","PreSelectedForImplantation"],"104A":["SQ","1","ToricIOLPowerForExactEmmetropiaSequence"],"104B":["SQ","1","ToricIOLPowerForExactTargetRefractionSequence"],1050:["SQ","1","OphthalmicAxialLengthMeasurementsSequence"],1053:["FL","1","IOLPower"],1054:["FL","1","PredictedRefractiveError"],1059:["FL","1","OphthalmicAxialLengthVelocity"],1065:["LO","1","LensStatusDescription"],1066:["LO","1","VitreousStatusDescription"],1090:["SQ","1","IOLPowerSequence"],1092:["SQ","1","LensConstantSequence"],1093:["LO","1","IOLManufacturer"],1094:["LO","1","LensConstantDescription"],1095:["LO","1","ImplantName"],1096:["SQ","1","KeratometryMeasurementTypeCodeSequence"],1097:["LO","1","ImplantPartNumber"],1100:["SQ","1","ReferencedOphthalmicAxialMeasurementsSequence"],1101:["SQ","1","OphthalmicAxialLengthMeasurementsSegmentNameCodeSequence"],1103:["SQ","1","RefractiveErrorBeforeRefractiveSurgeryCodeSequence"],1121:["FL","1","IOLPowerForExactEmmetropia"],1122:["FL","1","IOLPowerForExactTargetRefraction"],1125:["SQ","1","AnteriorChamberDepthDefinitionCodeSequence"],1127:["SQ","1","LensThicknessSequence"],1128:["SQ","1","AnteriorChamberDepthSequence"],"112A":["SQ","1","CalculationCommentSequence"],"112B":["CS","1","CalculationCommentType"],"112C":["LT","1","CalculationComment"],1130:["FL","1","LensThickness"],1131:["FL","1","AnteriorChamberDepth"],1132:["SQ","1","SourceOfLensThicknessDataCodeSequence"],1133:["SQ","1","SourceOfAnteriorChamberDepthDataCodeSequence"],1134:["SQ","1","SourceOfRefractiveMeasurementsSequence"],1135:["SQ","1","SourceOfRefractiveMeasurementsCodeSequence"],1140:["CS","1","OphthalmicAxialLengthMeasurementModified"],1150:["SQ","1","OphthalmicAxialLengthDataSourceCodeSequence"],1153:["SQ","1","OphthalmicAxialLengthAcquisitionMethodCodeSequence"],1155:["FL","1","SignalToNoiseRatio"],1159:["LO","1","OphthalmicAxialLengthDataSourceDescription"],1210:["SQ","1","OphthalmicAxialLengthMeasurementsTotalLengthSequence"],1211:["SQ","1","OphthalmicAxialLengthMeasurementsSegmentalLengthSequence"],1212:["SQ","1","OphthalmicAxialLengthMeasurementsLengthSummationSequence"],1220:["SQ","1","UltrasoundOphthalmicAxialLengthMeasurementsSequence"],1225:["SQ","1","OpticalOphthalmicAxialLengthMeasurementsSequence"],1230:["SQ","1","UltrasoundSelectedOphthalmicAxialLengthSequence"],1250:["SQ","1","OphthalmicAxialLengthSelectionMethodCodeSequence"],1255:["SQ","1","OpticalSelectedOphthalmicAxialLengthSequence"],1257:["SQ","1","SelectedSegmentalOphthalmicAxialLengthSequence"],1260:["SQ","1","SelectedTotalOphthalmicAxialLengthSequence"],1262:["SQ","1","OphthalmicAxialLengthQualityMetricSequence"],1265:["SQ","1","OphthalmicAxialLengthQualityMetricTypeCodeSequence"],1273:["LO","1","OphthalmicAxialLengthQualityMetricTypeDescription"],1300:["SQ","1","IntraocularLensCalculationsRightEyeSequence"],1310:["SQ","1","IntraocularLensCalculationsLeftEyeSequence"],1330:["SQ","1","ReferencedOphthalmicAxialLengthMeasurementQCImageSequence"],1415:["CS","1","OphthalmicMappingDeviceType"],1420:["SQ","1","AcquisitionMethodCodeSequence"],1423:["SQ","1","AcquisitionMethodAlgorithmSequence"],1436:["SQ","1","OphthalmicThicknessMapTypeCodeSequence"],1443:["SQ","1","OphthalmicThicknessMappingNormalsSequence"],1445:["SQ","1","RetinalThicknessDefinitionCodeSequence"],1450:["SQ","1","PixelValueMappingToCodedConceptSequence"],1452:["xs","1","MappedPixelValue"],1454:["LO","1","PixelValueMappingExplanation"],1458:["SQ","1","OphthalmicThicknessMapQualityThresholdSequence"],1460:["FL","1","OphthalmicThicknessMapThresholdQualityRating"],1463:["FL","2","AnatomicStructureReferencePoint"],1465:["SQ","1","RegistrationToLocalizerSequence"],1466:["CS","1","RegisteredLocalizerUnits"],1467:["FL","2","RegisteredLocalizerTopLeftHandCorner"],1468:["FL","2","RegisteredLocalizerBottomRightHandCorner"],1470:["SQ","1","OphthalmicThicknessMapQualityRatingSequence"],1472:["SQ","1","RelevantOPTAttributesSequence"],1512:["SQ","1","TransformationMethodCodeSequence"],1513:["SQ","1","TransformationAlgorithmSequence"],1515:["CS","1","OphthalmicAxialLengthMethod"],1517:["FL","1","OphthalmicFOV"],1518:["SQ","1","TwoDimensionalToThreeDimensionalMapSequence"],1525:["SQ","1","WideFieldOphthalmicPhotographyQualityRatingSequence"],1526:["SQ","1","WideFieldOphthalmicPhotographyQualityThresholdSequence"],1527:["FL","1","WideFieldOphthalmicPhotographyThresholdQualityRating"],1528:["FL","1","XCoordinatesCenterPixelViewAngle"],1529:["FL","1","YCoordinatesCenterPixelViewAngle"],1530:["UL","1","NumberOfMapPoints"],1531:["OF","1","TwoDimensionalToThreeDimensionalMapData"],1612:["SQ","1","DerivationAlgorithmSequence"],1615:["SQ","1","OphthalmicImageTypeCodeSequence"],1616:["LO","1","OphthalmicImageTypeDescription"],1618:["SQ","1","ScanPatternTypeCodeSequence"],1620:["SQ","1","ReferencedSurfaceMeshIdentificationSequence"],1622:["CS","1","OphthalmicVolumetricPropertiesFlag"],1624:["FL","1","OphthalmicAnatomicReferencePointXCoordinate"],1626:["FL","1","OphthalmicAnatomicReferencePointYCoordinate"],1628:["SQ","1","OphthalmicEnFaceImageQualityRatingSequence"],1630:["DS","1","QualityThreshold"],1640:["SQ","1","OCTBscanAnalysisAcquisitionParametersSequence"],1642:["UL","1","NumberOfBscansPerFrame"],1643:["FL","1","BscanSlabThickness"],1644:["FL","1","DistanceBetweenBscanSlabs"],1645:["FL","1","BscanCycleTime"],1646:["FL","1-n","BscanCycleTimeVector"],1649:["FL","1","AscanRate"],1650:["FL","1","BscanRate"],1658:["UL","1","SurfaceMeshZPixelOffset"]},"0024":{"0000":["UL","1","GenericGroupLength"],"0010":["FL","1","VisualFieldHorizontalExtent"],"0011":["FL","1","VisualFieldVerticalExtent"],"0012":["CS","1","VisualFieldShape"],"0016":["SQ","1","ScreeningTestModeCodeSequence"],"0018":["FL","1","MaximumStimulusLuminance"],"0020":["FL","1","BackgroundLuminance"],"0021":["SQ","1","StimulusColorCodeSequence"],"0024":["SQ","1","BackgroundIlluminationColorCodeSequence"],"0025":["FL","1","StimulusArea"],"0028":["FL","1","StimulusPresentationTime"],"0032":["SQ","1","FixationSequence"],"0033":["SQ","1","FixationMonitoringCodeSequence"],"0034":["SQ","1","VisualFieldCatchTrialSequence"],"0035":["US","1","FixationCheckedQuantity"],"0036":["US","1","PatientNotProperlyFixatedQuantity"],"0037":["CS","1","PresentedVisualStimuliDataFlag"],"0038":["US","1","NumberOfVisualStimuli"],"0039":["CS","1","ExcessiveFixationLossesDataFlag"],"0040":["CS","1","ExcessiveFixationLosses"],"0042":["US","1","StimuliRetestingQuantity"],"0044":["LT","1","CommentsOnPatientPerformanceOfVisualField"],"0045":["CS","1","FalseNegativesEstimateFlag"],"0046":["FL","1","FalseNegativesEstimate"],"0048":["US","1","NegativeCatchTrialsQuantity"],"0050":["US","1","FalseNegativesQuantity"],"0051":["CS","1","ExcessiveFalseNegativesDataFlag"],"0052":["CS","1","ExcessiveFalseNegatives"],"0053":["CS","1","FalsePositivesEstimateFlag"],"0054":["FL","1","FalsePositivesEstimate"],"0055":["CS","1","CatchTrialsDataFlag"],"0056":["US","1","PositiveCatchTrialsQuantity"],"0057":["CS","1","TestPointNormalsDataFlag"],"0058":["SQ","1","TestPointNormalsSequence"],"0059":["CS","1","GlobalDeviationProbabilityNormalsFlag"],"0060":["US","1","FalsePositivesQuantity"],"0061":["CS","1","ExcessiveFalsePositivesDataFlag"],"0062":["CS","1","ExcessiveFalsePositives"],"0063":["CS","1","VisualFieldTestNormalsFlag"],"0064":["SQ","1","ResultsNormalsSequence"],"0065":["SQ","1","AgeCorrectedSensitivityDeviationAlgorithmSequence"],"0066":["FL","1","GlobalDeviationFromNormal"],"0067":["SQ","1","GeneralizedDefectSensitivityDeviationAlgorithmSequence"],"0068":["FL","1","LocalizedDeviationFromNormal"],"0069":["LO","1","PatientReliabilityIndicator"],"0070":["FL","1","VisualFieldMeanSensitivity"],"0071":["FL","1","GlobalDeviationProbability"],"0072":["CS","1","LocalDeviationProbabilityNormalsFlag"],"0073":["FL","1","LocalizedDeviationProbability"],"0074":["CS","1","ShortTermFluctuationCalculated"],"0075":["FL","1","ShortTermFluctuation"],"0076":["CS","1","ShortTermFluctuationProbabilityCalculated"],"0077":["FL","1","ShortTermFluctuationProbability"],"0078":["CS","1","CorrectedLocalizedDeviationFromNormalCalculated"],"0079":["FL","1","CorrectedLocalizedDeviationFromNormal"],"0080":["CS","1","CorrectedLocalizedDeviationFromNormalProbabilityCalculated"],"0081":["FL","1","CorrectedLocalizedDeviationFromNormalProbability"],"0083":["SQ","1","GlobalDeviationProbabilitySequence"],"0085":["SQ","1","LocalizedDeviationProbabilitySequence"],"0086":["CS","1","FovealSensitivityMeasured"],"0087":["FL","1","FovealSensitivity"],"0088":["FL","1","VisualFieldTestDuration"],"0089":["SQ","1","VisualFieldTestPointSequence"],"0090":["FL","1","VisualFieldTestPointXCoordinate"],"0091":["FL","1","VisualFieldTestPointYCoordinate"],"0092":["FL","1","AgeCorrectedSensitivityDeviationValue"],"0093":["CS","1","StimulusResults"],"0094":["FL","1","SensitivityValue"],"0095":["CS","1","RetestStimulusSeen"],"0096":["FL","1","RetestSensitivityValue"],"0097":["SQ","1","VisualFieldTestPointNormalsSequence"],"0098":["FL","1","QuantifiedDefect"],"0100":["FL","1","AgeCorrectedSensitivityDeviationProbabilityValue"],"0102":["CS","1","GeneralizedDefectCorrectedSensitivityDeviationFlag"],"0103":["FL","1","GeneralizedDefectCorrectedSensitivityDeviationValue"],"0104":["FL","1","GeneralizedDefectCorrectedSensitivityDeviationProbabilityValue"],"0105":["FL","1","MinimumSensitivityValue"],"0106":["CS","1","BlindSpotLocalized"],"0107":["FL","1","BlindSpotXCoordinate"],"0108":["FL","1","BlindSpotYCoordinate"],"0110":["SQ","1","VisualAcuityMeasurementSequence"],"0112":["SQ","1","RefractiveParametersUsedOnPatientSequence"],"0113":["CS","1","MeasurementLaterality"],"0114":["SQ","1","OphthalmicPatientClinicalInformationLeftEyeSequence"],"0115":["SQ","1","OphthalmicPatientClinicalInformationRightEyeSequence"],"0117":["CS","1","FovealPointNormativeDataFlag"],"0118":["FL","1","FovealPointProbabilityValue"],"0120":["CS","1","ScreeningBaselineMeasured"],"0122":["SQ","1","ScreeningBaselineMeasuredSequence"],"0124":["CS","1","ScreeningBaselineType"],"0126":["FL","1","ScreeningBaselineValue"],"0202":["LO","1","AlgorithmSource"],"0306":["LO","1","DataSetName"],"0307":["LO","1","DataSetVersion"],"0308":["LO","1","DataSetSource"],"0309":["LO","1","DataSetDescription"],"0317":["SQ","1","VisualFieldTestReliabilityGlobalIndexSequence"],"0320":["SQ","1","VisualFieldGlobalResultsIndexSequence"],"0325":["SQ","1","DataObservationSequence"],"0338":["CS","1","IndexNormalsFlag"],"0341":["FL","1","IndexProbability"],"0344":["SQ","1","IndexProbabilitySequence"]},"0028":{"0000":["UL","1","GenericGroupLength"],"0002":["US","1","SamplesPerPixel"],"0003":["US","1","SamplesPerPixelUsed"],"0004":["CS","1","PhotometricInterpretation"],"0005":["US","1","ImageDimensions"],"0006":["US","1","PlanarConfiguration"],"0008":["IS","1","NumberOfFrames"],"0009":["AT","1-n","FrameIncrementPointer"],"000A":["AT","1-n","FrameDimensionPointer"],"0010":["US","1","Rows"],"0011":["US","1","Columns"],"0012":["US","1","Planes"],"0014":["US","1","UltrasoundColorDataPresent"],"0020":["","",""],"0030":["DS","2","PixelSpacing"],"0031":["DS","2","ZoomFactor"],"0032":["DS","2","ZoomCenter"],"0034":["IS","2","PixelAspectRatio"],"0040":["CS","1","ImageFormat"],"0050":["LO","1-n","ManipulatedImage"],"0051":["CS","1-n","CorrectedImage"],"005F":["LO","1","CompressionRecognitionCode"],"0060":["CS","1","CompressionCode"],"0061":["SH","1","CompressionOriginator"],"0062":["LO","1","CompressionLabel"],"0063":["SH","1","CompressionDescription"],"0065":["CS","1-n","CompressionSequence"],"0066":["AT","1-n","CompressionStepPointers"],"0068":["US","1","RepeatInterval"],"0069":["US","1","BitsGrouped"],"0070":["US","1-n","PerimeterTable"],"0071":["xs","1","PerimeterValue"],"0080":["US","1","PredictorRows"],"0081":["US","1","PredictorColumns"],"0082":["US","1-n","PredictorConstants"],"0090":["CS","1","BlockedPixels"],"0091":["US","1","BlockRows"],"0092":["US","1","BlockColumns"],"0093":["US","1","RowOverlap"],"0094":["US","1","ColumnOverlap"],"0100":["US","1","BitsAllocated"],"0101":["US","1","BitsStored"],"0102":["US","1","HighBit"],"0103":["US","1","PixelRepresentation"],"0104":["xs","1","SmallestValidPixelValue"],"0105":["xs","1","LargestValidPixelValue"],"0106":["xs","1","SmallestImagePixelValue"],"0107":["xs","1","LargestImagePixelValue"],"0108":["xs","1","SmallestPixelValueInSeries"],"0109":["xs","1","LargestPixelValueInSeries"],"0110":["xs","1","SmallestImagePixelValueInPlane"],"0111":["xs","1","LargestImagePixelValueInPlane"],"0120":["xs","1","PixelPaddingValue"],"0121":["xs","1","PixelPaddingRangeLimit"],"0122":["FL","1","FloatPixelPaddingValue"],"0123":["FD","1","DoubleFloatPixelPaddingValue"],"0124":["FL","1","FloatPixelPaddingRangeLimit"],"0125":["FD","1","DoubleFloatPixelPaddingRangeLimit"],"0200":["US","1","ImageLocation"],"0300":["CS","1","QualityControlImage"],"0301":["CS","1","BurnedInAnnotation"],"0302":["CS","1","RecognizableVisualFeatures"],"0303":["CS","1","LongitudinalTemporalInformationModified"],"0304":["UI","1","ReferencedColorPaletteInstanceUID"],"0400":["LO","1","TransformLabel"],"0401":["LO","1","TransformVersionNumber"],"0402":["US","1","NumberOfTransformSteps"],"0403":["LO","1-n","SequenceOfCompressedData"],"0404":["AT","1-n","DetailsOfCoefficients"],"04x0":["US","1","RowsForNthOrderCoefficients"],"04x1":["US","1","ColumnsForNthOrderCoefficients"],"04x2":["LO","1-n","CoefficientCoding"],"04x3":["AT","1-n","CoefficientCodingPointers"],"0700":["LO","1","DCTLabel"],"0701":["CS","1-n","DataBlockDescription"],"0702":["AT","1-n","DataBlock"],"0710":["US","1","NormalizationFactorFormat"],"0720":["US","1","ZonalMapNumberFormat"],"0721":["AT","1-n","ZonalMapLocation"],"0722":["US","1","ZonalMapFormat"],"0730":["US","1","AdaptiveMapFormat"],"0740":["US","1","CodeNumberFormat"],"08x0":["CS","1-n","CodeLabel"],"08x2":["US","1","NumberOfTables"],"08x3":["AT","1-n","CodeTableLocation"],"08x4":["US","1","BitsForCodeWord"],"08x8":["AT","1-n","ImageDataLocation"],"0A02":["CS","1","PixelSpacingCalibrationType"],"0A04":["LO","1","PixelSpacingCalibrationDescription"],1040:["CS","1","PixelIntensityRelationship"],1041:["SS","1","PixelIntensityRelationshipSign"],1050:["DS","1-n","WindowCenter"],1051:["DS","1-n","WindowWidth"],1052:["DS","1","RescaleIntercept"],1053:["DS","1","RescaleSlope"],1054:["LO","1","RescaleType"],1055:["LO","1-n","WindowCenterWidthExplanation"],1056:["CS","1","VOILUTFunction"],1080:["CS","1","GrayScale"],1090:["CS","1","RecommendedViewingMode"],1100:["xs","3","GrayLookupTableDescriptor"],1101:["xs","3","RedPaletteColorLookupTableDescriptor"],1102:["xs","3","GreenPaletteColorLookupTableDescriptor"],1103:["xs","3","BluePaletteColorLookupTableDescriptor"],1104:["US","3","AlphaPaletteColorLookupTableDescriptor"],1111:["xs","4","LargeRedPaletteColorLookupTableDescriptor"],1112:["xs","4","LargeGreenPaletteColorLookupTableDescriptor"],1113:["xs","4","LargeBluePaletteColorLookupTableDescriptor"],1199:["UI","1","PaletteColorLookupTableUID"],1200:["xs","1-n or 1","GrayLookupTableData"],1201:["OW","1","RedPaletteColorLookupTableData"],1202:["OW","1","GreenPaletteColorLookupTableData"],1203:["OW","1","BluePaletteColorLookupTableData"],1204:["OW","1","AlphaPaletteColorLookupTableData"],1211:["OW","1","LargeRedPaletteColorLookupTableData"],1212:["OW","1","LargeGreenPaletteColorLookupTableData"],1213:["OW","1","LargeBluePaletteColorLookupTableData"],1214:["UI","1","LargePaletteColorLookupTableUID"],1221:["OW","1","SegmentedRedPaletteColorLookupTableData"],1222:["OW","1","SegmentedGreenPaletteColorLookupTableData"],1223:["OW","1","SegmentedBluePaletteColorLookupTableData"],1224:["OW","1","SegmentedAlphaPaletteColorLookupTableData"],1230:["SQ","1","StoredValueColorRangeSequence"],1231:["FD","1","MinimumStoredValueMapped"],1232:["FD","1","MaximumStoredValueMapped"],1300:["CS","1","BreastImplantPresent"],1350:["CS","1","PartialView"],1351:["ST","1","PartialViewDescription"],1352:["SQ","1","PartialViewCodeSequence"],"135A":["CS","1","SpatialLocationsPreserved"],1401:["SQ","1","DataFrameAssignmentSequence"],1402:["CS","1","DataPathAssignment"],1403:["US","1","BitsMappedToColorLookupTable"],1404:["SQ","1","BlendingLUT1Sequence"],1405:["CS","1","BlendingLUT1TransferFunction"],1406:["FD","1","BlendingWeightConstant"],1407:["US","3","BlendingLookupTableDescriptor"],1408:["OW","1","BlendingLookupTableData"],"140B":["SQ","1","EnhancedPaletteColorLookupTableSequence"],"140C":["SQ","1","BlendingLUT2Sequence"],"140D":["CS","1","BlendingLUT2TransferFunction"],"140E":["CS","1","DataPathID"],"140F":["CS","1","RGBLUTTransferFunction"],1410:["CS","1","AlphaLUTTransferFunction"],2e3:["OB","1","ICCProfile"],2002:["CS","1","ColorSpace"],2110:["CS","1","LossyImageCompression"],2112:["DS","1-n","LossyImageCompressionRatio"],2114:["CS","1-n","LossyImageCompressionMethod"],3e3:["SQ","1","ModalityLUTSequence"],3002:["xs","3","LUTDescriptor"],3003:["LO","1","LUTExplanation"],3004:["LO","1","ModalityLUTType"],3006:["xx","1-n or 1","LUTData"],3010:["SQ","1","VOILUTSequence"],3110:["SQ","1","SoftcopyVOILUTSequence"],4e3:["LT","1","ImagePresentationComments"],5e3:["SQ","1","BiPlaneAcquisitionSequence"],6010:["US","1","RepresentativeFrameNumber"],6020:["US","1-n","FrameNumbersOfInterest"],6022:["LO","1-n","FrameOfInterestDescription"],6023:["CS","1-n","FrameOfInterestType"],6030:["US","1-n","MaskPointers"],6040:["US","1-n","RWavePointer"],6100:["SQ","1","MaskSubtractionSequence"],6101:["CS","1","MaskOperation"],6102:["US","2-2n","ApplicableFrameRange"],6110:["US","1-n","MaskFrameNumbers"],6112:["US","1","ContrastFrameAveraging"],6114:["FL","2","MaskSubPixelShift"],6120:["SS","1","TIDOffset"],6190:["ST","1","MaskOperationExplanation"],7e3:["SQ","1","EquipmentAdministratorSequence"],7001:["US","1","NumberOfDisplaySubsystems"],7002:["US","1","CurrentConfigurationID"],7003:["US","1","DisplaySubsystemID"],7004:["SH","1","DisplaySubsystemName"],7005:["LO","1","DisplaySubsystemDescription"],7006:["CS","1","SystemStatus"],7007:["LO","1","SystemStatusComment"],7008:["SQ","1","TargetLuminanceCharacteristicsSequence"],7009:["US","1","LuminanceCharacteristicsID"],"700A":["SQ","1","DisplaySubsystemConfigurationSequence"],"700B":["US","1","ConfigurationID"],"700C":["SH","1","ConfigurationName"],"700D":["LO","1","ConfigurationDescription"],"700E":["US","1","ReferencedTargetLuminanceCharacteristicsID"],"700F":["SQ","1","QAResultsSequence"],7010:["SQ","1","DisplaySubsystemQAResultsSequence"],7011:["SQ","1","ConfigurationQAResultsSequence"],7012:["SQ","1","MeasurementEquipmentSequence"],7013:["CS","1-n","MeasurementFunctions"],7014:["CS","1","MeasurementEquipmentType"],7015:["SQ","1","VisualEvaluationResultSequence"],7016:["SQ","1","DisplayCalibrationResultSequence"],7017:["US","1","DDLValue"],7018:["FL","2","CIExyWhitePoint"],7019:["CS","1","DisplayFunctionType"],"701A":["FL","1","GammaValue"],"701B":["US","1","NumberOfLuminancePoints"],"701C":["SQ","1","LuminanceResponseSequence"],"701D":["FL","1","TargetMinimumLuminance"],"701E":["FL","1","TargetMaximumLuminance"],"701F":["FL","1","LuminanceValue"],7020:["LO","1","LuminanceResponseDescription"],7021:["CS","1","WhitePointFlag"],7022:["SQ","1","DisplayDeviceTypeCodeSequence"],7023:["SQ","1","DisplaySubsystemSequence"],7024:["SQ","1","LuminanceResultSequence"],7025:["CS","1","AmbientLightValueSource"],7026:["CS","1-n","MeasuredCharacteristics"],7027:["SQ","1","LuminanceUniformityResultSequence"],7028:["SQ","1","VisualEvaluationTestSequence"],7029:["CS","1","TestResult"],"702A":["LO","1","TestResultComment"],"702B":["CS","1","TestImageValidation"],"702C":["SQ","1","TestPatternCodeSequence"],"702D":["SQ","1","MeasurementPatternCodeSequence"],"702E":["SQ","1","VisualEvaluationMethodCodeSequence"],"7FE0":["UR","1","PixelDataProviderURL"],9001:["UL","1","DataPointRows"],9002:["UL","1","DataPointColumns"],9003:["CS","1","SignalDomainColumns"],9099:["US","1","LargestMonochromePixelValue"],9108:["CS","1","DataRepresentation"],9110:["SQ","1","PixelMeasuresSequence"],9132:["SQ","1","FrameVOILUTSequence"],9145:["SQ","1","PixelValueTransformationSequence"],9235:["CS","1","SignalDomainRows"],9411:["FL","1","DisplayFilterPercentage"],9415:["SQ","1","FramePixelShiftSequence"],9416:["US","1","SubtractionItemID"],9422:["SQ","1","PixelIntensityRelationshipLUTSequence"],9443:["SQ","1","FramePixelDataPropertiesSequence"],9444:["CS","1","GeometricalProperties"],9445:["FL","1","GeometricMaximumDistortion"],9446:["CS","1-n","ImageProcessingApplied"],9454:["CS","1","MaskSelectionMode"],9474:["CS","1","LUTFunction"],9478:["FL","1","MaskVisibilityPercentage"],9501:["SQ","1","PixelShiftSequence"],9502:["SQ","1","RegionPixelShiftSequence"],9503:["SS","2-2n","VerticesOfTheRegion"],9505:["SQ","1","MultiFramePresentationSequence"],9506:["US","2-2n","PixelShiftFrameRange"],9507:["US","2-2n","LUTFrameRange"],9520:["DS","16","ImageToEquipmentMappingMatrix"],9537:["CS","1","EquipmentCoordinateSystemIdentification"]},"0032":{"0000":["UL","1","GenericGroupLength"],"000A":["CS","1","StudyStatusID"],"000C":["CS","1","StudyPriorityID"],"0012":["LO","1","StudyIDIssuer"],"0032":["DA","1","StudyVerifiedDate"],"0033":["TM","1","StudyVerifiedTime"],"0034":["DA","1","StudyReadDate"],"0035":["TM","1","StudyReadTime"],1e3:["DA","1","ScheduledStudyStartDate"],1001:["TM","1","ScheduledStudyStartTime"],1010:["DA","1","ScheduledStudyStopDate"],1011:["TM","1","ScheduledStudyStopTime"],1020:["LO","1","ScheduledStudyLocation"],1021:["AE","1-n","ScheduledStudyLocationAETitle"],1030:["LO","1","ReasonForStudy"],1031:["SQ","1","RequestingPhysicianIdentificationSequence"],1032:["PN","1","RequestingPhysician"],1033:["LO","1","RequestingService"],1034:["SQ","1","RequestingServiceCodeSequence"],1040:["DA","1","StudyArrivalDate"],1041:["TM","1","StudyArrivalTime"],1050:["DA","1","StudyCompletionDate"],1051:["TM","1","StudyCompletionTime"],1055:["CS","1","StudyComponentStatusID"],1060:["LO","1","RequestedProcedureDescription"],1064:["SQ","1","RequestedProcedureCodeSequence"],1065:["SQ","1","RequestedLateralityCodeSequence"],1066:["UT","1","ReasonForVisit"],1067:["SQ","1","ReasonForVisitCodeSequence"],1070:["LO","1","RequestedContrastAgent"],4e3:["LT","1","StudyComments"]},"0034":{"0000":["UL","1","GenericGroupLength"],"0001":["SQ","1","FlowIdentifierSequence"],"0002":["OB","1","FlowIdentifier"],"0003":["UI","1","FlowTransferSyntaxUID"],"0004":["UL","1","FlowRTPSamplingRate"],"0005":["OB","1","SourceIdentifier"],"0007":["OB","1","FrameOriginTimestamp"],"0008":["CS","1","IncludesImagingSubject"],"0009":["SQ","1","FrameUsefulnessGroupSequence"],"000A":["SQ","1","RealTimeBulkDataFlowSequence"],"000B":["SQ","1","CameraPositionGroupSequence"],"000C":["CS","1","IncludesInformation"],"000D":["SQ","1","TimeOfFrameGroupSequence"]},"0038":{"0000":["UL","1","GenericGroupLength"],"0004":["SQ","1","ReferencedPatientAliasSequence"],"0008":["CS","1","VisitStatusID"],"0010":["LO","1","AdmissionID"],"0011":["LO","1","IssuerOfAdmissionID"],"0014":["SQ","1","IssuerOfAdmissionIDSequence"],"0016":["LO","1","RouteOfAdmissions"],"001A":["DA","1","ScheduledAdmissionDate"],"001B":["TM","1","ScheduledAdmissionTime"],"001C":["DA","1","ScheduledDischargeDate"],"001D":["TM","1","ScheduledDischargeTime"],"001E":["LO","1","ScheduledPatientInstitutionResidence"],"0020":["DA","1","AdmittingDate"],"0021":["TM","1","AdmittingTime"],"0030":["DA","1","DischargeDate"],"0032":["TM","1","DischargeTime"],"0040":["LO","1","DischargeDiagnosisDescription"],"0044":["SQ","1","DischargeDiagnosisCodeSequence"],"0050":["LO","1","SpecialNeeds"],"0060":["LO","1","ServiceEpisodeID"],"0061":["LO","1","IssuerOfServiceEpisodeID"],"0062":["LO","1","ServiceEpisodeDescription"],"0064":["SQ","1","IssuerOfServiceEpisodeIDSequence"],"0100":["SQ","1","PertinentDocumentsSequence"],"0101":["SQ","1","PertinentResourcesSequence"],"0102":["LO","1","ResourceDescription"],"0300":["LO","1","CurrentPatientLocation"],"0400":["LO","1","PatientInstitutionResidence"],"0500":["LO","1","PatientState"],"0502":["SQ","1","PatientClinicalTrialParticipationSequence"],4e3:["LT","1","VisitComments"]},"003A":{"0000":["UL","1","GenericGroupLength"],"0004":["CS","1","WaveformOriginality"],"0005":["US","1","NumberOfWaveformChannels"],"0010":["UL","1","NumberOfWaveformSamples"],"001A":["DS","1","SamplingFrequency"],"0020":["SH","1","MultiplexGroupLabel"],"0200":["SQ","1","ChannelDefinitionSequence"],"0202":["IS","1","WaveformChannelNumber"],"0203":["SH","1","ChannelLabel"],"0205":["CS","1-n","ChannelStatus"],"0208":["SQ","1","ChannelSourceSequence"],"0209":["SQ","1","ChannelSourceModifiersSequence"],"020A":["SQ","1","SourceWaveformSequence"],"020C":["LO","1","ChannelDerivationDescription"],"0210":["DS","1","ChannelSensitivity"],"0211":["SQ","1","ChannelSensitivityUnitsSequence"],"0212":["DS","1","ChannelSensitivityCorrectionFactor"],"0213":["DS","1","ChannelBaseline"],"0214":["DS","1","ChannelTimeSkew"],"0215":["DS","1","ChannelSampleSkew"],"0218":["DS","1","ChannelOffset"],"021A":["US","1","WaveformBitsStored"],"0220":["DS","1","FilterLowFrequency"],"0221":["DS","1","FilterHighFrequency"],"0222":["DS","1","NotchFilterFrequency"],"0223":["DS","1","NotchFilterBandwidth"],"0230":["FL","1","WaveformDataDisplayScale"],"0231":["US","3","WaveformDisplayBackgroundCIELabValue"],"0240":["SQ","1","WaveformPresentationGroupSequence"],"0241":["US","1","PresentationGroupNumber"],"0242":["SQ","1","ChannelDisplaySequence"],"0244":["US","3","ChannelRecommendedDisplayCIELabValue"],"0245":["FL","1","ChannelPosition"],"0246":["CS","1","DisplayShadingFlag"],"0247":["FL","1","FractionalChannelDisplayScale"],"0248":["FL","1","AbsoluteChannelDisplayScale"],"0300":["SQ","1","MultiplexedAudioChannelsDescriptionCodeSequence"],"0301":["IS","1","ChannelIdentificationCode"],"0302":["CS","1","ChannelMode"],"0310":["UI","1","MultiplexGroupUID"],"0311":["DS","1","PowerlineFrequency"],"0312":["SQ","1","ChannelImpedanceSequence"],"0313":["DS","1","ImpedanceValue"],"0314":["DT","1","ImpedanceMeasurementDateTime"],"0315":["DS","1","ImpedanceMeasurementFrequency"],"0316":["CS","1","ImpedanceMeasurementCurrentType"]},"0040":{"0000":["UL","1","GenericGroupLength"],"0001":["AE","1-n","ScheduledStationAETitle"],"0002":["DA","1","ScheduledProcedureStepStartDate"],"0003":["TM","1","ScheduledProcedureStepStartTime"],"0004":["DA","1","ScheduledProcedureStepEndDate"],"0005":["TM","1","ScheduledProcedureStepEndTime"],"0006":["PN","1","ScheduledPerformingPhysicianName"],"0007":["LO","1","ScheduledProcedureStepDescription"],"0008":["SQ","1","ScheduledProtocolCodeSequence"],"0009":["SH","1","ScheduledProcedureStepID"],"000A":["SQ","1","StageCodeSequence"],"000B":["SQ","1","ScheduledPerformingPhysicianIdentificationSequence"],"0010":["SH","1-n","ScheduledStationName"],"0011":["SH","1","ScheduledProcedureStepLocation"],"0012":["LO","1","PreMedication"],"0020":["CS","1","ScheduledProcedureStepStatus"],"0026":["SQ","1","OrderPlacerIdentifierSequence"],"0027":["SQ","1","OrderFillerIdentifierSequence"],"0031":["UT","1","LocalNamespaceEntityID"],"0032":["UT","1","UniversalEntityID"],"0033":["CS","1","UniversalEntityIDType"],"0035":["CS","1","IdentifierTypeCode"],"0036":["SQ","1","AssigningFacilitySequence"],"0039":["SQ","1","AssigningJurisdictionCodeSequence"],"003A":["SQ","1","AssigningAgencyOrDepartmentCodeSequence"],"0100":["SQ","1","ScheduledProcedureStepSequence"],"0220":["SQ","1","ReferencedNonImageCompositeSOPInstanceSequence"],"0241":["AE","1","PerformedStationAETitle"],"0242":["SH","1","PerformedStationName"],"0243":["SH","1","PerformedLocation"],"0244":["DA","1","PerformedProcedureStepStartDate"],"0245":["TM","1","PerformedProcedureStepStartTime"],"0250":["DA","1","PerformedProcedureStepEndDate"],"0251":["TM","1","PerformedProcedureStepEndTime"],"0252":["CS","1","PerformedProcedureStepStatus"],"0253":["SH","1","PerformedProcedureStepID"],"0254":["LO","1","PerformedProcedureStepDescription"],"0255":["LO","1","PerformedProcedureTypeDescription"],"0260":["SQ","1","PerformedProtocolCodeSequence"],"0261":["CS","1","PerformedProtocolType"],"0270":["SQ","1","ScheduledStepAttributesSequence"],"0275":["SQ","1","RequestAttributesSequence"],"0280":["ST","1","CommentsOnThePerformedProcedureStep"],"0281":["SQ","1","PerformedProcedureStepDiscontinuationReasonCodeSequence"],"0293":["SQ","1","QuantitySequence"],"0294":["DS","1","Quantity"],"0295":["SQ","1","MeasuringUnitsSequence"],"0296":["SQ","1","BillingItemSequence"],"0300":["US","1","TotalTimeOfFluoroscopy"],"0301":["US","1","TotalNumberOfExposures"],"0302":["US","1","EntranceDose"],"0303":["US","1-2","ExposedArea"],"0306":["DS","1","DistanceSourceToEntrance"],"0307":["DS","1","DistanceSourceToSupport"],"030E":["SQ","1","ExposureDoseSequence"],"0310":["ST","1","CommentsOnRadiationDose"],"0312":["DS","1","XRayOutput"],"0314":["DS","1","HalfValueLayer"],"0316":["DS","1","OrganDose"],"0318":["CS","1","OrganExposed"],"0320":["SQ","1","BillingProcedureStepSequence"],"0321":["SQ","1","FilmConsumptionSequence"],"0324":["SQ","1","BillingSuppliesAndDevicesSequence"],"0330":["SQ","1","ReferencedProcedureStepSequence"],"0340":["SQ","1","PerformedSeriesSequence"],"0400":["LT","1","CommentsOnTheScheduledProcedureStep"],"0440":["SQ","1","ProtocolContextSequence"],"0441":["SQ","1","ContentItemModifierSequence"],"0500":["SQ","1","ScheduledSpecimenSequence"],"050A":["LO","1","SpecimenAccessionNumber"],"0512":["LO","1","ContainerIdentifier"],"0513":["SQ","1","IssuerOfTheContainerIdentifierSequence"],"0515":["SQ","1","AlternateContainerIdentifierSequence"],"0518":["SQ","1","ContainerTypeCodeSequence"],"051A":["LO","1","ContainerDescription"],"0520":["SQ","1","ContainerComponentSequence"],"0550":["SQ","1","SpecimenSequence"],"0551":["LO","1","SpecimenIdentifier"],"0552":["SQ","1","SpecimenDescriptionSequenceTrial"],"0553":["ST","1","SpecimenDescriptionTrial"],"0554":["UI","1","SpecimenUID"],"0555":["SQ","1","AcquisitionContextSequence"],"0556":["ST","1","AcquisitionContextDescription"],"0560":["SQ","1","SpecimenDescriptionSequence"],"0562":["SQ","1","IssuerOfTheSpecimenIdentifierSequence"],"059A":["SQ","1","SpecimenTypeCodeSequence"],"0600":["LO","1","SpecimenShortDescription"],"0602":["UT","1","SpecimenDetailedDescription"],"0610":["SQ","1","SpecimenPreparationSequence"],"0612":["SQ","1","SpecimenPreparationStepContentItemSequence"],"0620":["SQ","1","SpecimenLocalizationContentItemSequence"],"06FA":["LO","1","SlideIdentifier"],"0710":["SQ","1","WholeSlideMicroscopyImageFrameTypeSequence"],"071A":["SQ","1","ImageCenterPointCoordinatesSequence"],"072A":["DS","1","XOffsetInSlideCoordinateSystem"],"073A":["DS","1","YOffsetInSlideCoordinateSystem"],"074A":["DS","1","ZOffsetInSlideCoordinateSystem"],"08D8":["SQ","1","PixelSpacingSequence"],"08DA":["SQ","1","CoordinateSystemAxisCodeSequence"],"08EA":["SQ","1","MeasurementUnitsCodeSequence"],"09F8":["SQ","1","VitalStainCodeSequenceTrial"],1001:["SH","1","RequestedProcedureID"],1002:["LO","1","ReasonForTheRequestedProcedure"],1003:["SH","1","RequestedProcedurePriority"],1004:["LO","1","PatientTransportArrangements"],1005:["LO","1","RequestedProcedureLocation"],1006:["SH","1","PlacerOrderNumberProcedure"],1007:["SH","1","FillerOrderNumberProcedure"],1008:["LO","1","ConfidentialityCode"],1009:["SH","1","ReportingPriority"],"100A":["SQ","1","ReasonForRequestedProcedureCodeSequence"],1010:["PN","1-n","NamesOfIntendedRecipientsOfResults"],1011:["SQ","1","IntendedRecipientsOfResultsIdentificationSequence"],1012:["SQ","1","ReasonForPerformedProcedureCodeSequence"],1060:["LO","1","RequestedProcedureDescriptionTrial"],1101:["SQ","1","PersonIdentificationCodeSequence"],1102:["ST","1","PersonAddress"],1103:["LO","1-n","PersonTelephoneNumbers"],1104:["LT","1","PersonTelecomInformation"],1400:["LT","1","RequestedProcedureComments"],2001:["LO","1","ReasonForTheImagingServiceRequest"],2004:["DA","1","IssueDateOfImagingServiceRequest"],2005:["TM","1","IssueTimeOfImagingServiceRequest"],2006:["SH","1","PlacerOrderNumberImagingServiceRequestRetired"],2007:["SH","1","FillerOrderNumberImagingServiceRequestRetired"],2008:["PN","1","OrderEnteredBy"],2009:["SH","1","OrderEntererLocation"],2010:["SH","1","OrderCallbackPhoneNumber"],2011:["LT","1","OrderCallbackTelecomInformation"],2016:["LO","1","PlacerOrderNumberImagingServiceRequest"],2017:["LO","1","FillerOrderNumberImagingServiceRequest"],2400:["LT","1","ImagingServiceRequestComments"],3001:["LO","1","ConfidentialityConstraintOnPatientDataDescription"],4001:["CS","1","GeneralPurposeScheduledProcedureStepStatus"],4002:["CS","1","GeneralPurposePerformedProcedureStepStatus"],4003:["CS","1","GeneralPurposeScheduledProcedureStepPriority"],4004:["SQ","1","ScheduledProcessingApplicationsCodeSequence"],4005:["DT","1","ScheduledProcedureStepStartDateTime"],4006:["CS","1","MultipleCopiesFlag"],4007:["SQ","1","PerformedProcessingApplicationsCodeSequence"],4008:["DT","1","ScheduledProcedureStepExpirationDateTime"],4009:["SQ","1","HumanPerformerCodeSequence"],4010:["DT","1","ScheduledProcedureStepModificationDateTime"],4011:["DT","1","ExpectedCompletionDateTime"],4015:["SQ","1","ResultingGeneralPurposePerformedProcedureStepsSequence"],4016:["SQ","1","ReferencedGeneralPurposeScheduledProcedureStepSequence"],4018:["SQ","1","ScheduledWorkitemCodeSequence"],4019:["SQ","1","PerformedWorkitemCodeSequence"],4020:["CS","1","InputAvailabilityFlag"],4021:["SQ","1","InputInformationSequence"],4022:["SQ","1","RelevantInformationSequence"],4023:["UI","1","ReferencedGeneralPurposeScheduledProcedureStepTransactionUID"],4025:["SQ","1","ScheduledStationNameCodeSequence"],4026:["SQ","1","ScheduledStationClassCodeSequence"],4027:["SQ","1","ScheduledStationGeographicLocationCodeSequence"],4028:["SQ","1","PerformedStationNameCodeSequence"],4029:["SQ","1","PerformedStationClassCodeSequence"],4030:["SQ","1","PerformedStationGeographicLocationCodeSequence"],4031:["SQ","1","RequestedSubsequentWorkitemCodeSequence"],4032:["SQ","1","NonDICOMOutputCodeSequence"],4033:["SQ","1","OutputInformationSequence"],4034:["SQ","1","ScheduledHumanPerformersSequence"],4035:["SQ","1","ActualHumanPerformersSequence"],4036:["LO","1","HumanPerformerOrganization"],4037:["PN","1","HumanPerformerName"],4040:["CS","1","RawDataHandling"],4041:["CS","1","InputReadinessState"],4050:["DT","1","PerformedProcedureStepStartDateTime"],4051:["DT","1","PerformedProcedureStepEndDateTime"],4052:["DT","1","ProcedureStepCancellationDateTime"],4070:["SQ","1","OutputDestinationSequence"],4071:["SQ","1","DICOMStorageSequence"],4072:["SQ","1","STOWRSStorageSequence"],4073:["UR","1","StorageURL"],4074:["SQ","1","XDSStorageSequence"],8302:["DS","1","EntranceDoseInmGy"],8303:["CS","1","EntranceDoseDerivation"],9092:["SQ","1","ParametricMapFrameTypeSequence"],9094:["SQ","1","ReferencedImageRealWorldValueMappingSequence"],9096:["SQ","1","RealWorldValueMappingSequence"],9098:["SQ","1","PixelValueMappingCodeSequence"],9210:["SH","1","LUTLabel"],9211:["xs","1","RealWorldValueLastValueMapped"],9212:["FD","1-n","RealWorldValueLUTData"],9213:["FD","1","DoubleFloatRealWorldValueLastValueMapped"],9214:["FD","1","DoubleFloatRealWorldValueFirstValueMapped"],9216:["xs","1","RealWorldValueFirstValueMapped"],9220:["SQ","1","QuantityDefinitionSequence"],9224:["FD","1","RealWorldValueIntercept"],9225:["FD","1","RealWorldValueSlope"],A007:["CS","1","FindingsFlagTrial"],A010:["CS","1","RelationshipType"],A020:["SQ","1","FindingsSequenceTrial"],A021:["UI","1","FindingsGroupUIDTrial"],A022:["UI","1","ReferencedFindingsGroupUIDTrial"],A023:["DA","1","FindingsGroupRecordingDateTrial"],A024:["TM","1","FindingsGroupRecordingTimeTrial"],A026:["SQ","1","FindingsSourceCategoryCodeSequenceTrial"],A027:["LO","1","VerifyingOrganization"],A028:["SQ","1","DocumentingOrganizationIdentifierCodeSequenceTrial"],A030:["DT","1","VerificationDateTime"],A032:["DT","1","ObservationDateTime"],A033:["DT","1","ObservationStartDateTime"],A040:["CS","1","ValueType"],A043:["SQ","1","ConceptNameCodeSequence"],A047:["LO","1","MeasurementPrecisionDescriptionTrial"],A050:["CS","1","ContinuityOfContent"],A057:["CS","1-n","UrgencyOrPriorityAlertsTrial"],A060:["LO","1","SequencingIndicatorTrial"],A066:["SQ","1","DocumentIdentifierCodeSequenceTrial"],A067:["PN","1","DocumentAuthorTrial"],A068:["SQ","1","DocumentAuthorIdentifierCodeSequenceTrial"],A070:["SQ","1","IdentifierCodeSequenceTrial"],A073:["SQ","1","VerifyingObserverSequence"],A074:["OB","1","ObjectBinaryIdentifierTrial"],A075:["PN","1","VerifyingObserverName"],A076:["SQ","1","DocumentingObserverIdentifierCodeSequenceTrial"],A078:["SQ","1","AuthorObserverSequence"],A07A:["SQ","1","ParticipantSequence"],A07C:["SQ","1","CustodialOrganizationSequence"],A080:["CS","1","ParticipationType"],A082:["DT","1","ParticipationDateTime"],A084:["CS","1","ObserverType"],A085:["SQ","1","ProcedureIdentifierCodeSequenceTrial"],A088:["SQ","1","VerifyingObserverIdentificationCodeSequence"],A089:["OB","1","ObjectDirectoryBinaryIdentifierTrial"],A090:["SQ","1","EquivalentCDADocumentSequence"],A0B0:["US","2-2n","ReferencedWaveformChannels"],A110:["DA","1","DateOfDocumentOrVerbalTransactionTrial"],A112:["TM","1","TimeOfDocumentCreationOrVerbalTransactionTrial"],A120:["DT","1","DateTime"],A121:["DA","1","Date"],A122:["TM","1","Time"],A123:["PN","1","PersonName"],A124:["UI","1","UID"],A125:["CS","2","ReportStatusIDTrial"],A130:["CS","1","TemporalRangeType"],A132:["UL","1-n","ReferencedSamplePositions"],A136:["US","1-n","ReferencedFrameNumbers"],A138:["DS","1-n","ReferencedTimeOffsets"],A13A:["DT","1-n","ReferencedDateTime"],A160:["UT","1","TextValue"],A161:["FD","1-n","FloatingPointValue"],A162:["SL","1-n","RationalNumeratorValue"],A163:["UL","1-n","RationalDenominatorValue"],A167:["SQ","1","ObservationCategoryCodeSequenceTrial"],A168:["SQ","1","ConceptCodeSequence"],A16A:["ST","1","BibliographicCitationTrial"],A170:["SQ","1","PurposeOfReferenceCodeSequence"],A171:["UI","1","ObservationUID"],A172:["UI","1","ReferencedObservationUIDTrial"],A173:["CS","1","ReferencedObservationClassTrial"],A174:["CS","1","ReferencedObjectObservationClassTrial"],A180:["US","1","AnnotationGroupNumber"],A192:["DA","1","ObservationDateTrial"],A193:["TM","1","ObservationTimeTrial"],A194:["CS","1","MeasurementAutomationTrial"],A195:["SQ","1","ModifierCodeSequence"],A224:["ST","1","IdentificationDescriptionTrial"],A290:["CS","1","CoordinatesSetGeometricTypeTrial"],A296:["SQ","1","AlgorithmCodeSequenceTrial"],A297:["ST","1","AlgorithmDescriptionTrial"],A29A:["SL","2-2n","PixelCoordinatesSetTrial"],A300:["SQ","1","MeasuredValueSequence"],A301:["SQ","1","NumericValueQualifierCodeSequence"],A307:["PN","1","CurrentObserverTrial"],A30A:["DS","1-n","NumericValue"],A313:["SQ","1","ReferencedAccessionSequenceTrial"],A33A:["ST","1","ReportStatusCommentTrial"],A340:["SQ","1","ProcedureContextSequenceTrial"],A352:["PN","1","VerbalSourceTrial"],A353:["ST","1","AddressTrial"],A354:["LO","1","TelephoneNumberTrial"],A358:["SQ","1","VerbalSourceIdentifierCodeSequenceTrial"],A360:["SQ","1","PredecessorDocumentsSequence"],A370:["SQ","1","ReferencedRequestSequence"],A372:["SQ","1","PerformedProcedureCodeSequence"],A375:["SQ","1","CurrentRequestedProcedureEvidenceSequence"],A380:["SQ","1","ReportDetailSequenceTrial"],A385:["SQ","1","PertinentOtherEvidenceSequence"],A390:["SQ","1","HL7StructuredDocumentReferenceSequence"],A402:["UI","1","ObservationSubjectUIDTrial"],A403:["CS","1","ObservationSubjectClassTrial"],A404:["SQ","1","ObservationSubjectTypeCodeSequenceTrial"],A491:["CS","1","CompletionFlag"],A492:["LO","1","CompletionFlagDescription"],A493:["CS","1","VerificationFlag"],A494:["CS","1","ArchiveRequested"],A496:["CS","1","PreliminaryFlag"],A504:["SQ","1","ContentTemplateSequence"],A525:["SQ","1","IdenticalDocumentsSequence"],A600:["CS","1","ObservationSubjectContextFlagTrial"],A601:["CS","1","ObserverContextFlagTrial"],A603:["CS","1","ProcedureContextFlagTrial"],A730:["SQ","1","ContentSequence"],A731:["SQ","1","RelationshipSequenceTrial"],A732:["SQ","1","RelationshipTypeCodeSequenceTrial"],A744:["SQ","1","LanguageCodeSequenceTrial"],A801:["SQ","1","TabulatedValuesSequence"],A802:["UL","1","NumberOfTableRows"],A803:["UL","1","NumberOfTableColumns"],A804:["UL","1","TableRowNumber"],A805:["UL","1","TableColumnNumber"],A806:["SQ","1","TableRowDefinitionSequence"],A807:["SQ","1","TableColumnDefinitionSequence"],A808:["SQ","1","CellValuesSequence"],A992:["ST","1","UniformResourceLocatorTrial"],B020:["SQ","1","WaveformAnnotationSequence"],DB00:["CS","1","TemplateIdentifier"],DB06:["DT","1","TemplateVersion"],DB07:["DT","1","TemplateLocalVersion"],DB0B:["CS","1","TemplateExtensionFlag"],DB0C:["UI","1","TemplateExtensionOrganizationUID"],DB0D:["UI","1","TemplateExtensionCreatorUID"],DB73:["UL","1-n","ReferencedContentItemIdentifier"],E001:["ST","1","HL7InstanceIdentifier"],E004:["DT","1","HL7DocumentEffectiveTime"],E006:["SQ","1","HL7DocumentTypeCodeSequence"],E008:["SQ","1","DocumentClassCodeSequence"],E010:["UR","1","RetrieveURI"],E011:["UI","1","RetrieveLocationUID"],E020:["CS","1","TypeOfInstances"],E021:["SQ","1","DICOMRetrievalSequence"],E022:["SQ","1","DICOMMediaRetrievalSequence"],E023:["SQ","1","WADORetrievalSequence"],E024:["SQ","1","XDSRetrievalSequence"],E025:["SQ","1","WADORSRetrievalSequence"],E030:["UI","1","RepositoryUniqueID"],E031:["UI","1","HomeCommunityID"]},"0042":{"0000":["UL","1","GenericGroupLength"],"0010":["ST","1","DocumentTitle"],"0011":["OB","1","EncapsulatedDocument"],"0012":["LO","1","MIMETypeOfEncapsulatedDocument"],"0013":["SQ","1","SourceInstanceSequence"],"0014":["LO","1-n","ListOfMIMETypes"],"0015":["UL","1","EncapsulatedDocumentLength"]},"0044":{"0000":["UL","1","GenericGroupLength"],"0001":["ST","1","ProductPackageIdentifier"],"0002":["CS","1","SubstanceAdministrationApproval"],"0003":["LT","1","ApprovalStatusFurtherDescription"],"0004":["DT","1","ApprovalStatusDateTime"],"0007":["SQ","1","ProductTypeCodeSequence"],"0008":["LO","1-n","ProductName"],"0009":["LT","1","ProductDescription"],"000A":["LO","1","ProductLotIdentifier"],"000B":["DT","1","ProductExpirationDateTime"],"0010":["DT","1","SubstanceAdministrationDateTime"],"0011":["LO","1","SubstanceAdministrationNotes"],"0012":["LO","1","SubstanceAdministrationDeviceID"],"0013":["SQ","1","ProductParameterSequence"],"0019":["SQ","1","SubstanceAdministrationParameterSequence"],"0100":["SQ","1","ApprovalSequence"],"0101":["SQ","1","AssertionCodeSequence"],"0102":["UI","1","AssertionUID"],"0103":["SQ","1","AsserterIdentificationSequence"],"0104":["DT","1","AssertionDateTime"],"0105":["DT","1","AssertionExpirationDateTime"],"0106":["UT","1","AssertionComments"],"0107":["SQ","1","RelatedAssertionSequence"],"0108":["UI","1","ReferencedAssertionUID"],"0109":["SQ","1","ApprovalSubjectSequence"],"010A":["SQ","1","OrganizationalRoleCodeSequence"]},"0046":{"0000":["UL","1","GenericGroupLength"],"0012":["LO","1","LensDescription"],"0014":["SQ","1","RightLensSequence"],"0015":["SQ","1","LeftLensSequence"],"0016":["SQ","1","UnspecifiedLateralityLensSequence"],"0018":["SQ","1","CylinderSequence"],"0028":["SQ","1","PrismSequence"],"0030":["FD","1","HorizontalPrismPower"],"0032":["CS","1","HorizontalPrismBase"],"0034":["FD","1","VerticalPrismPower"],"0036":["CS","1","VerticalPrismBase"],"0038":["CS","1","LensSegmentType"],"0040":["FD","1","OpticalTransmittance"],"0042":["FD","1","ChannelWidth"],"0044":["FD","1","PupilSize"],"0046":["FD","1","CornealSize"],"0047":["SQ","1","CornealSizeSequence"],"0050":["SQ","1","AutorefractionRightEyeSequence"],"0052":["SQ","1","AutorefractionLeftEyeSequence"],"0060":["FD","1","DistancePupillaryDistance"],"0062":["FD","1","NearPupillaryDistance"],"0063":["FD","1","IntermediatePupillaryDistance"],"0064":["FD","1","OtherPupillaryDistance"],"0070":["SQ","1","KeratometryRightEyeSequence"],"0071":["SQ","1","KeratometryLeftEyeSequence"],"0074":["SQ","1","SteepKeratometricAxisSequence"],"0075":["FD","1","RadiusOfCurvature"],"0076":["FD","1","KeratometricPower"],"0077":["FD","1","KeratometricAxis"],"0080":["SQ","1","FlatKeratometricAxisSequence"],"0092":["CS","1","BackgroundColor"],"0094":["CS","1","Optotype"],"0095":["CS","1","OptotypePresentation"],"0097":["SQ","1","SubjectiveRefractionRightEyeSequence"],"0098":["SQ","1","SubjectiveRefractionLeftEyeSequence"],"0100":["SQ","1","AddNearSequence"],"0101":["SQ","1","AddIntermediateSequence"],"0102":["SQ","1","AddOtherSequence"],"0104":["FD","1","AddPower"],"0106":["FD","1","ViewingDistance"],"0110":["SQ","1","CorneaMeasurementsSequence"],"0111":["SQ","1","SourceOfCorneaMeasurementDataCodeSequence"],"0112":["SQ","1","SteepCornealAxisSequence"],"0113":["SQ","1","FlatCornealAxisSequence"],"0114":["FD","1","CornealPower"],"0115":["FD","1","CornealAxis"],"0116":["SQ","1","CorneaMeasurementMethodCodeSequence"],"0117":["FL","1","RefractiveIndexOfCornea"],"0118":["FL","1","RefractiveIndexOfAqueousHumor"],"0121":["SQ","1","VisualAcuityTypeCodeSequence"],"0122":["SQ","1","VisualAcuityRightEyeSequence"],"0123":["SQ","1","VisualAcuityLeftEyeSequence"],"0124":["SQ","1","VisualAcuityBothEyesOpenSequence"],"0125":["CS","1","ViewingDistanceType"],"0135":["SS","2","VisualAcuityModifiers"],"0137":["FD","1","DecimalVisualAcuity"],"0139":["LO","1","OptotypeDetailedDefinition"],"0145":["SQ","1","ReferencedRefractiveMeasurementsSequence"],"0146":["FD","1","SpherePower"],"0147":["FD","1","CylinderPower"],"0201":["CS","1","CornealTopographySurface"],"0202":["FL","2","CornealVertexLocation"],"0203":["FL","1","PupilCentroidXCoordinate"],"0204":["FL","1","PupilCentroidYCoordinate"],"0205":["FL","1","EquivalentPupilRadius"],"0207":["SQ","1","CornealTopographyMapTypeCodeSequence"],"0208":["IS","2-2n","VerticesOfTheOutlineOfPupil"],"0210":["SQ","1","CornealTopographyMappingNormalsSequence"],"0211":["SQ","1","MaximumCornealCurvatureSequence"],"0212":["FL","1","MaximumCornealCurvature"],"0213":["FL","2","MaximumCornealCurvatureLocation"],"0215":["SQ","1","MinimumKeratometricSequence"],"0218":["SQ","1","SimulatedKeratometricCylinderSequence"],"0220":["FL","1","AverageCornealPower"],"0224":["FL","1","CornealISValue"],"0227":["FL","1","AnalyzedArea"],"0230":["FL","1","SurfaceRegularityIndex"],"0232":["FL","1","SurfaceAsymmetryIndex"],"0234":["FL","1","CornealEccentricityIndex"],"0236":["FL","1","KeratoconusPredictionIndex"],"0238":["FL","1","DecimalPotentialVisualAcuity"],"0242":["CS","1","CornealTopographyMapQualityEvaluation"],"0244":["SQ","1","SourceImageCornealProcessedDataSequence"],"0247":["FL","3","CornealPointLocation"],"0248":["CS","1","CornealPointEstimated"],"0249":["FL","1","AxialPower"],"0250":["FL","1","TangentialPower"],"0251":["FL","1","RefractivePower"],"0252":["FL","1","RelativeElevation"],"0253":["FL","1","CornealWavefront"]},"0048":{"0000":["UL","1","GenericGroupLength"],"0001":["FL","1","ImagedVolumeWidth"],"0002":["FL","1","ImagedVolumeHeight"],"0003":["FL","1","ImagedVolumeDepth"],"0006":["UL","1","TotalPixelMatrixColumns"],"0007":["UL","1","TotalPixelMatrixRows"],"0008":["SQ","1","TotalPixelMatrixOriginSequence"],"0010":["CS","1","SpecimenLabelInImage"],"0011":["CS","1","FocusMethod"],"0012":["CS","1","ExtendedDepthOfField"],"0013":["US","1","NumberOfFocalPlanes"],"0014":["FL","1","DistanceBetweenFocalPlanes"],"0015":["US","3","RecommendedAbsentPixelCIELabValue"],"0100":["SQ","1","IlluminatorTypeCodeSequence"],"0102":["DS","6","ImageOrientationSlide"],"0105":["SQ","1","OpticalPathSequence"],"0106":["SH","1","OpticalPathIdentifier"],"0107":["ST","1","OpticalPathDescription"],"0108":["SQ","1","IlluminationColorCodeSequence"],"0110":["SQ","1","SpecimenReferenceSequence"],"0111":["DS","1","CondenserLensPower"],"0112":["DS","1","ObjectiveLensPower"],"0113":["DS","1","ObjectiveLensNumericalAperture"],"0120":["SQ","1","PaletteColorLookupTableSequence"],"0200":["SQ","1","ReferencedImageNavigationSequence"],"0201":["US","2","TopLeftHandCornerOfLocalizerArea"],"0202":["US","2","BottomRightHandCornerOfLocalizerArea"],"0207":["SQ","1","OpticalPathIdentificationSequence"],"021A":["SQ","1","PlanePositionSlideSequence"],"021E":["SL","1","ColumnPositionInTotalImagePixelMatrix"],"021F":["SL","1","RowPositionInTotalImagePixelMatrix"],"0301":["CS","1","PixelOriginInterpretation"],"0302":["UL","1","NumberOfOpticalPaths"],"0303":["UL","1","TotalPixelMatrixFocalPlanes"]},"0050":{"0000":["UL","1","GenericGroupLength"],"0004":["CS","1","CalibrationImage"],"0010":["SQ","1","DeviceSequence"],"0012":["SQ","1","ContainerComponentTypeCodeSequence"],"0013":["FD","1","ContainerComponentThickness"],"0014":["DS","1","DeviceLength"],"0015":["FD","1","ContainerComponentWidth"],"0016":["DS","1","DeviceDiameter"],"0017":["CS","1","DeviceDiameterUnits"],"0018":["DS","1","DeviceVolume"],"0019":["DS","1","InterMarkerDistance"],"001A":["CS","1","ContainerComponentMaterial"],"001B":["LO","1","ContainerComponentID"],"001C":["FD","1","ContainerComponentLength"],"001D":["FD","1","ContainerComponentDiameter"],"001E":["LO","1","ContainerComponentDescription"],"0020":["LO","1","DeviceDescription"],"0021":["ST","1","LongDeviceDescription"]},"0052":{"0000":["UL","1","GenericGroupLength"],"0001":["FL","1","ContrastBolusIngredientPercentByVolume"],"0002":["FD","1","OCTFocalDistance"],"0003":["FD","1","BeamSpotSize"],"0004":["FD","1","EffectiveRefractiveIndex"],"0006":["CS","1","OCTAcquisitionDomain"],"0007":["FD","1","OCTOpticalCenterWavelength"],"0008":["FD","1","AxialResolution"],"0009":["FD","1","RangingDepth"],"0011":["FD","1","ALineRate"],"0012":["US","1","ALinesPerFrame"],"0013":["FD","1","CatheterRotationalRate"],"0014":["FD","1","ALinePixelSpacing"],"0016":["SQ","1","ModeOfPercutaneousAccessSequence"],"0025":["SQ","1","IntravascularOCTFrameTypeSequence"],"0026":["CS","1","OCTZOffsetApplied"],"0027":["SQ","1","IntravascularFrameContentSequence"],"0028":["FD","1","IntravascularLongitudinalDistance"],"0029":["SQ","1","IntravascularOCTFrameContentSequence"],"0030":["SS","1","OCTZOffsetCorrection"],"0031":["CS","1","CatheterDirectionOfRotation"],"0033":["FD","1","SeamLineLocation"],"0034":["FD","1","FirstALineLocation"],"0036":["US","1","SeamLineIndex"],"0038":["US","1","NumberOfPaddedALines"],"0039":["CS","1","InterpolationType"],"003A":["CS","1","RefractiveIndexApplied"]},"0054":{"0000":["UL","1","GenericGroupLength"],"0010":["US","1-n","EnergyWindowVector"],"0011":["US","1","NumberOfEnergyWindows"],"0012":["SQ","1","EnergyWindowInformationSequence"],"0013":["SQ","1","EnergyWindowRangeSequence"],"0014":["DS","1","EnergyWindowLowerLimit"],"0015":["DS","1","EnergyWindowUpperLimit"],"0016":["SQ","1","RadiopharmaceuticalInformationSequence"],"0017":["IS","1","ResidualSyringeCounts"],"0018":["SH","1","EnergyWindowName"],"0020":["US","1-n","DetectorVector"],"0021":["US","1","NumberOfDetectors"],"0022":["SQ","1","DetectorInformationSequence"],"0030":["US","1-n","PhaseVector"],"0031":["US","1","NumberOfPhases"],"0032":["SQ","1","PhaseInformationSequence"],"0033":["US","1","NumberOfFramesInPhase"],"0036":["IS","1","PhaseDelay"],"0038":["IS","1","PauseBetweenFrames"],"0039":["CS","1","PhaseDescription"],"0050":["US","1-n","RotationVector"],"0051":["US","1","NumberOfRotations"],"0052":["SQ","1","RotationInformationSequence"],"0053":["US","1","NumberOfFramesInRotation"],"0060":["US","1-n","RRIntervalVector"],"0061":["US","1","NumberOfRRIntervals"],"0062":["SQ","1","GatedInformationSequence"],"0063":["SQ","1","DataInformationSequence"],"0070":["US","1-n","TimeSlotVector"],"0071":["US","1","NumberOfTimeSlots"],"0072":["SQ","1","TimeSlotInformationSequence"],"0073":["DS","1","TimeSlotTime"],"0080":["US","1-n","SliceVector"],"0081":["US","1","NumberOfSlices"],"0090":["US","1-n","AngularViewVector"],"0100":["US","1-n","TimeSliceVector"],"0101":["US","1","NumberOfTimeSlices"],"0200":["DS","1","StartAngle"],"0202":["CS","1","TypeOfDetectorMotion"],"0210":["IS","1-n","TriggerVector"],"0211":["US","1","NumberOfTriggersInPhase"],"0220":["SQ","1","ViewCodeSequence"],"0222":["SQ","1","ViewModifierCodeSequence"],"0300":["SQ","1","RadionuclideCodeSequence"],"0302":["SQ","1","AdministrationRouteCodeSequence"],"0304":["SQ","1","RadiopharmaceuticalCodeSequence"],"0306":["SQ","1","CalibrationDataSequence"],"0308":["US","1","EnergyWindowNumber"],"0400":["SH","1","ImageID"],"0410":["SQ","1","PatientOrientationCodeSequence"],"0412":["SQ","1","PatientOrientationModifierCodeSequence"],"0414":["SQ","1","PatientGantryRelationshipCodeSequence"],"0500":["CS","1","SliceProgressionDirection"],"0501":["CS","1","ScanProgressionDirection"],1e3:["CS","2","SeriesType"],1001:["CS","1","Units"],1002:["CS","1","CountsSource"],1004:["CS","1","ReprojectionMethod"],1006:["CS","1","SUVType"],1100:["CS","1","RandomsCorrectionMethod"],1101:["LO","1","AttenuationCorrectionMethod"],1102:["CS","1","DecayCorrection"],1103:["LO","1","ReconstructionMethod"],1104:["LO","1","DetectorLinesOfResponseUsed"],1105:["LO","1","ScatterCorrectionMethod"],1200:["DS","1","AxialAcceptance"],1201:["IS","2","AxialMash"],1202:["IS","1","TransverseMash"],1203:["DS","2","DetectorElementSize"],1210:["DS","1","CoincidenceWindowWidth"],1220:["CS","1-n","SecondaryCountsType"],1300:["DS","1","FrameReferenceTime"],1310:["IS","1","PrimaryPromptsCountsAccumulated"],1311:["IS","1-n","SecondaryCountsAccumulated"],1320:["DS","1","SliceSensitivityFactor"],1321:["DS","1","DecayFactor"],1322:["DS","1","DoseCalibrationFactor"],1323:["DS","1","ScatterFractionFactor"],1324:["DS","1","DeadTimeFactor"],1330:["US","1","ImageIndex"],1400:["CS","1-n","CountsIncluded"],1401:["CS","1","DeadTimeCorrectionFlag"]},"0060":{"0000":["UL","1","GenericGroupLength"],3e3:["SQ","1","HistogramSequence"],3002:["US","1","HistogramNumberOfBins"],3004:["xs","1","HistogramFirstBinValue"],3006:["xs","1","HistogramLastBinValue"],3008:["US","1","HistogramBinWidth"],3010:["LO","1","HistogramExplanation"],3020:["UL","1-n","HistogramData"]},"0062":{"0000":["UL","1","GenericGroupLength"],"0001":["CS","1","SegmentationType"],"0002":["SQ","1","SegmentSequence"],"0003":["SQ","1","SegmentedPropertyCategoryCodeSequence"],"0004":["US","1","SegmentNumber"],"0005":["LO","1","SegmentLabel"],"0006":["ST","1","SegmentDescription"],"0007":["SQ","1","SegmentationAlgorithmIdentificationSequence"],"0008":["CS","1","SegmentAlgorithmType"],"0009":["LO","1-n","SegmentAlgorithmName"],"000A":["SQ","1","SegmentIdentificationSequence"],"000B":["US","1-n","ReferencedSegmentNumber"],"000C":["US","1","RecommendedDisplayGrayscaleValue"],"000D":["US","3","RecommendedDisplayCIELabValue"],"000E":["US","1","MaximumFractionalValue"],"000F":["SQ","1","SegmentedPropertyTypeCodeSequence"],"0010":["CS","1","SegmentationFractionalType"],"0011":["SQ","1","SegmentedPropertyTypeModifierCodeSequence"],"0012":["SQ","1","UsedSegmentsSequence"],"0013":["CS","1","SegmentsOverlap"],"0020":["UT","1","TrackingID"],"0021":["UI","1","TrackingUID"]},"0064":{"0000":["UL","1","GenericGroupLength"],"0002":["SQ","1","DeformableRegistrationSequence"],"0003":["UI","1","SourceFrameOfReferenceUID"],"0005":["SQ","1","DeformableRegistrationGridSequence"],"0007":["UL","3","GridDimensions"],"0008":["FD","3","GridResolution"],"0009":["OF","1","VectorGridData"],"000F":["SQ","1","PreDeformationMatrixRegistrationSequence"],"0010":["SQ","1","PostDeformationMatrixRegistrationSequence"]},"0066":{"0000":["UL","1","GenericGroupLength"],"0001":["UL","1","NumberOfSurfaces"],"0002":["SQ","1","SurfaceSequence"],"0003":["UL","1","SurfaceNumber"],"0004":["LT","1","SurfaceComments"],"0009":["CS","1","SurfaceProcessing"],"000A":["FL","1","SurfaceProcessingRatio"],"000B":["LO","1","SurfaceProcessingDescription"],"000C":["FL","1","RecommendedPresentationOpacity"],"000D":["CS","1","RecommendedPresentationType"],"000E":["CS","1","FiniteVolume"],"0010":["CS","1","Manifold"],"0011":["SQ","1","SurfacePointsSequence"],"0012":["SQ","1","SurfacePointsNormalsSequence"],"0013":["SQ","1","SurfaceMeshPrimitivesSequence"],"0015":["UL","1","NumberOfSurfacePoints"],"0016":["OF","1","PointCoordinatesData"],"0017":["FL","3","PointPositionAccuracy"],"0018":["FL","1","MeanPointDistance"],"0019":["FL","1","MaximumPointDistance"],"001A":["FL","6","PointsBoundingBoxCoordinates"],"001B":["FL","3","AxisOfRotation"],"001C":["FL","3","CenterOfRotation"],"001E":["UL","1","NumberOfVectors"],"001F":["US","1","VectorDimensionality"],"0020":["FL","1-n","VectorAccuracy"],"0021":["OF","1","VectorCoordinateData"],"0022":["OD","1","DoublePointCoordinatesData"],"0023":["OW","1","TrianglePointIndexList"],"0024":["OW","1","EdgePointIndexList"],"0025":["OW","1","VertexPointIndexList"],"0026":["SQ","1","TriangleStripSequence"],"0027":["SQ","1","TriangleFanSequence"],"0028":["SQ","1","LineSequence"],"0029":["OW","1","PrimitivePointIndexList"],"002A":["UL","1","SurfaceCount"],"002B":["SQ","1","ReferencedSurfaceSequence"],"002C":["UL","1","ReferencedSurfaceNumber"],"002D":["SQ","1","SegmentSurfaceGenerationAlgorithmIdentificationSequence"],"002E":["SQ","1","SegmentSurfaceSourceInstanceSequence"],"002F":["SQ","1","AlgorithmFamilyCodeSequence"],"0030":["SQ","1","AlgorithmNameCodeSequence"],"0031":["LO","1","AlgorithmVersion"],"0032":["LT","1","AlgorithmParameters"],"0034":["SQ","1","FacetSequence"],"0035":["SQ","1","SurfaceProcessingAlgorithmIdentificationSequence"],"0036":["LO","1","AlgorithmName"],"0037":["FL","1","RecommendedPointRadius"],"0038":["FL","1","RecommendedLineThickness"],"0040":["OL","1","LongPrimitivePointIndexList"],"0041":["OL","1","LongTrianglePointIndexList"],"0042":["OL","1","LongEdgePointIndexList"],"0043":["OL","1","LongVertexPointIndexList"],"0101":["SQ","1","TrackSetSequence"],"0102":["SQ","1","TrackSequence"],"0103":["OW","1","RecommendedDisplayCIELabValueList"],"0104":["SQ","1","TrackingAlgorithmIdentificationSequence"],"0105":["UL","1","TrackSetNumber"],"0106":["LO","1","TrackSetLabel"],"0107":["UT","1","TrackSetDescription"],"0108":["SQ","1","TrackSetAnatomicalTypeCodeSequence"],"0121":["SQ","1","MeasurementsSequence"],"0124":["SQ","1","TrackSetStatisticsSequence"],"0125":["OF","1","FloatingPointValues"],"0129":["OL","1","TrackPointIndexList"],"0130":["SQ","1","TrackStatisticsSequence"],"0132":["SQ","1","MeasurementValuesSequence"],"0133":["SQ","1","DiffusionAcquisitionCodeSequence"],"0134":["SQ","1","DiffusionModelCodeSequence"]},"0068":{"0000":["UL","1","GenericGroupLength"],6210:["LO","1","ImplantSize"],6221:["LO","1","ImplantTemplateVersion"],6222:["SQ","1","ReplacedImplantTemplateSequence"],6223:["CS","1","ImplantType"],6224:["SQ","1","DerivationImplantTemplateSequence"],6225:["SQ","1","OriginalImplantTemplateSequence"],6226:["DT","1","EffectiveDateTime"],6230:["SQ","1","ImplantTargetAnatomySequence"],6260:["SQ","1","InformationFromManufacturerSequence"],6265:["SQ","1","NotificationFromManufacturerSequence"],6270:["DT","1","InformationIssueDateTime"],6280:["ST","1","InformationSummary"],"62A0":["SQ","1","ImplantRegulatoryDisapprovalCodeSequence"],"62A5":["FD","1","OverallTemplateSpatialTolerance"],"62C0":["SQ","1","HPGLDocumentSequence"],"62D0":["US","1","HPGLDocumentID"],"62D5":["LO","1","HPGLDocumentLabel"],"62E0":["SQ","1","ViewOrientationCodeSequence"],"62F0":["SQ","1","ViewOrientationModifierCodeSequence"],"62F2":["FD","1","HPGLDocumentScaling"],6300:["OB","1","HPGLDocument"],6310:["US","1","HPGLContourPenNumber"],6320:["SQ","1","HPGLPenSequence"],6330:["US","1","HPGLPenNumber"],6340:["LO","1","HPGLPenLabel"],6345:["ST","1","HPGLPenDescription"],6346:["FD","2","RecommendedRotationPoint"],6347:["FD","4","BoundingRectangle"],6350:["US","1-n","ImplantTemplate3DModelSurfaceNumber"],6360:["SQ","1","SurfaceModelDescriptionSequence"],6380:["LO","1","SurfaceModelLabel"],6390:["FD","1","SurfaceModelScalingFactor"],"63A0":["SQ","1","MaterialsCodeSequence"],"63A4":["SQ","1","CoatingMaterialsCodeSequence"],"63A8":["SQ","1","ImplantTypeCodeSequence"],"63AC":["SQ","1","FixationMethodCodeSequence"],"63B0":["SQ","1","MatingFeatureSetsSequence"],"63C0":["US","1","MatingFeatureSetID"],"63D0":["LO","1","MatingFeatureSetLabel"],"63E0":["SQ","1","MatingFeatureSequence"],"63F0":["US","1","MatingFeatureID"],6400:["SQ","1","MatingFeatureDegreeOfFreedomSequence"],6410:["US","1","DegreeOfFreedomID"],6420:["CS","1","DegreeOfFreedomType"],6430:["SQ","1","TwoDMatingFeatureCoordinatesSequence"],6440:["US","1","ReferencedHPGLDocumentID"],6450:["FD","2","TwoDMatingPoint"],6460:["FD","4","TwoDMatingAxes"],6470:["SQ","1","TwoDDegreeOfFreedomSequence"],6490:["FD","3","ThreeDDegreeOfFreedomAxis"],"64A0":["FD","2","RangeOfFreedom"],"64C0":["FD","3","ThreeDMatingPoint"],"64D0":["FD","9","ThreeDMatingAxes"],"64F0":["FD","3","TwoDDegreeOfFreedomAxis"],6500:["SQ","1","PlanningLandmarkPointSequence"],6510:["SQ","1","PlanningLandmarkLineSequence"],6520:["SQ","1","PlanningLandmarkPlaneSequence"],6530:["US","1","PlanningLandmarkID"],6540:["LO","1","PlanningLandmarkDescription"],6545:["SQ","1","PlanningLandmarkIdentificationCodeSequence"],6550:["SQ","1","TwoDPointCoordinatesSequence"],6560:["FD","2","TwoDPointCoordinates"],6590:["FD","3","ThreeDPointCoordinates"],"65A0":["SQ","1","TwoDLineCoordinatesSequence"],"65B0":["FD","4","TwoDLineCoordinates"],"65D0":["FD","6","ThreeDLineCoordinates"],"65E0":["SQ","1","TwoDPlaneCoordinatesSequence"],"65F0":["FD","4","TwoDPlaneIntersection"],6610:["FD","3","ThreeDPlaneOrigin"],6620:["FD","3","ThreeDPlaneNormal"],7001:["CS","1","ModelModification"],7002:["CS","1","ModelMirroring"],7003:["SQ","1","ModelUsageCodeSequence"],7004:["UI","1","ModelGroupUID"],7005:["UR","1","RelativeURIReferenceWithinEncapsulatedDocument"]},"006A":{"0000":["UL","1","GenericGroupLength"],"0001":["CS","1","AnnotationCoordinateType"],"0002":["SQ","1","AnnotationGroupSequence"],"0003":["UI","1","AnnotationGroupUID"],"0005":["LO","1","AnnotationGroupLabel"],"0006":["UT","1","AnnotationGroupDescription"],"0007":["CS","1","AnnotationGroupGenerationType"],"0008":["SQ","1","AnnotationGroupAlgorithmIdentificationSequence"],"0009":["SQ","1","AnnotationPropertyCategoryCodeSequence"],"000A":["SQ","1","AnnotationPropertyTypeCodeSequence"],"000B":["SQ","1","AnnotationPropertyTypeModifierCodeSequence"],"000C":["UL","1","NumberOfAnnotations"],"000D":["CS","1","AnnotationAppliesToAllOpticalPaths"],"000E":["SH","1-n","ReferencedOpticalPathIdentifier"],"000F":["CS","1","AnnotationAppliesToAllZPlanes"],"0010":["FD","1-n","CommonZCoordinateValue"],"0011":["OL","1","AnnotationIndexList"]},"0070":{"0000":["UL","1","GenericGroupLength"],"0001":["SQ","1","GraphicAnnotationSequence"],"0002":["CS","1","GraphicLayer"],"0003":["CS","1","BoundingBoxAnnotationUnits"],"0004":["CS","1","AnchorPointAnnotationUnits"],"0005":["CS","1","GraphicAnnotationUnits"],"0006":["ST","1","UnformattedTextValue"],"0008":["SQ","1","TextObjectSequence"],"0009":["SQ","1","GraphicObjectSequence"],"0010":["FL","2","BoundingBoxTopLeftHandCorner"],"0011":["FL","2","BoundingBoxBottomRightHandCorner"],"0012":["CS","1","BoundingBoxTextHorizontalJustification"],"0014":["FL","2","AnchorPoint"],"0015":["CS","1","AnchorPointVisibility"],"0020":["US","1","GraphicDimensions"],"0021":["US","1","NumberOfGraphicPoints"],"0022":["FL","2-n","GraphicData"],"0023":["CS","1","GraphicType"],"0024":["CS","1","GraphicFilled"],"0040":["IS","1","ImageRotationRetired"],"0041":["CS","1","ImageHorizontalFlip"],"0042":["US","1","ImageRotation"],"0050":["US","2","DisplayedAreaTopLeftHandCornerTrial"],"0051":["US","2","DisplayedAreaBottomRightHandCornerTrial"],"0052":["SL","2","DisplayedAreaTopLeftHandCorner"],"0053":["SL","2","DisplayedAreaBottomRightHandCorner"],"005A":["SQ","1","DisplayedAreaSelectionSequence"],"0060":["SQ","1","GraphicLayerSequence"],"0062":["IS","1","GraphicLayerOrder"],"0066":["US","1","GraphicLayerRecommendedDisplayGrayscaleValue"],"0067":["US","3","GraphicLayerRecommendedDisplayRGBValue"],"0068":["LO","1","GraphicLayerDescription"],"0080":["CS","1","ContentLabel"],"0081":["LO","1","ContentDescription"],"0082":["DA","1","PresentationCreationDate"],"0083":["TM","1","PresentationCreationTime"],"0084":["PN","1","ContentCreatorName"],"0086":["SQ","1","ContentCreatorIdentificationCodeSequence"],"0087":["SQ","1","AlternateContentDescriptionSequence"],"0100":["CS","1","PresentationSizeMode"],"0101":["DS","2","PresentationPixelSpacing"],"0102":["IS","2","PresentationPixelAspectRatio"],"0103":["FL","1","PresentationPixelMagnificationRatio"],"0207":["LO","1","GraphicGroupLabel"],"0208":["ST","1","GraphicGroupDescription"],"0209":["SQ","1","CompoundGraphicSequence"],"0226":["UL","1","CompoundGraphicInstanceID"],"0227":["LO","1","FontName"],"0228":["CS","1","FontNameType"],"0229":["LO","1","CSSFontName"],"0230":["FD","1","RotationAngle"],"0231":["SQ","1","TextStyleSequence"],"0232":["SQ","1","LineStyleSequence"],"0233":["SQ","1","FillStyleSequence"],"0234":["SQ","1","GraphicGroupSequence"],"0241":["US","3","TextColorCIELabValue"],"0242":["CS","1","HorizontalAlignment"],"0243":["CS","1","VerticalAlignment"],"0244":["CS","1","ShadowStyle"],"0245":["FL","1","ShadowOffsetX"],"0246":["FL","1","ShadowOffsetY"],"0247":["US","3","ShadowColorCIELabValue"],"0248":["CS","1","Underlined"],"0249":["CS","1","Bold"],"0250":["CS","1","Italic"],"0251":["US","3","PatternOnColorCIELabValue"],"0252":["US","3","PatternOffColorCIELabValue"],"0253":["FL","1","LineThickness"],"0254":["CS","1","LineDashingStyle"],"0255":["UL","1","LinePattern"],"0256":["OB","1","FillPattern"],"0257":["CS","1","FillMode"],"0258":["FL","1","ShadowOpacity"],"0261":["FL","1","GapLength"],"0262":["FL","1","DiameterOfVisibility"],"0273":["FL","2","RotationPoint"],"0274":["CS","1","TickAlignment"],"0278":["CS","1","ShowTickLabel"],"0279":["CS","1","TickLabelAlignment"],"0282":["CS","1","CompoundGraphicUnits"],"0284":["FL","1","PatternOnOpacity"],"0285":["FL","1","PatternOffOpacity"],"0287":["SQ","1","MajorTicksSequence"],"0288":["FL","1","TickPosition"],"0289":["SH","1","TickLabel"],"0294":["CS","1","CompoundGraphicType"],"0295":["UL","1","GraphicGroupID"],"0306":["CS","1","ShapeType"],"0308":["SQ","1","RegistrationSequence"],"0309":["SQ","1","MatrixRegistrationSequence"],"030A":["SQ","1","MatrixSequence"],"030B":["FD","16","FrameOfReferenceToDisplayedCoordinateSystemTransformationMatrix"],"030C":["CS","1","FrameOfReferenceTransformationMatrixType"],"030D":["SQ","1","RegistrationTypeCodeSequence"],"030F":["ST","1","FiducialDescription"],"0310":["SH","1","FiducialIdentifier"],"0311":["SQ","1","FiducialIdentifierCodeSequence"],"0312":["FD","1","ContourUncertaintyRadius"],"0314":["SQ","1","UsedFiducialsSequence"],"0318":["SQ","1","GraphicCoordinatesDataSequence"],"031A":["UI","1","FiducialUID"],"031B":["UI","1","ReferencedFiducialUID"],"031C":["SQ","1","FiducialSetSequence"],"031E":["SQ","1","FiducialSequence"],"031F":["SQ","1","FiducialsPropertyCategoryCodeSequence"],"0401":["US","3","GraphicLayerRecommendedDisplayCIELabValue"],"0402":["SQ","1","BlendingSequence"],"0403":["FL","1","RelativeOpacity"],"0404":["SQ","1","ReferencedSpatialRegistrationSequence"],"0405":["CS","1","BlendingPosition"],1101:["UI","1","PresentationDisplayCollectionUID"],1102:["UI","1","PresentationSequenceCollectionUID"],1103:["US","1","PresentationSequencePositionIndex"],1104:["SQ","1","RenderedImageReferenceSequence"],1201:["SQ","1","VolumetricPresentationStateInputSequence"],1202:["CS","1","PresentationInputType"],1203:["US","1","InputSequencePositionIndex"],1204:["CS","1","Crop"],1205:["US","1-n","CroppingSpecificationIndex"],1206:["CS","1","CompositingMethod"],1207:["US","1","VolumetricPresentationInputNumber"],1208:["CS","1","ImageVolumeGeometry"],1209:["UI","1","VolumetricPresentationInputSetUID"],"120A":["SQ","1","VolumetricPresentationInputSetSequence"],"120B":["CS","1","GlobalCrop"],"120C":["US","1-n","GlobalCroppingSpecificationIndex"],"120D":["CS","1","RenderingMethod"],1301:["SQ","1","VolumeCroppingSequence"],1302:["CS","1","VolumeCroppingMethod"],1303:["FD","6","BoundingBoxCrop"],1304:["SQ","1","ObliqueCroppingPlaneSequence"],1305:["FD","4","Plane"],1306:["FD","3","PlaneNormal"],1309:["US","1","CroppingSpecificationNumber"],1501:["CS","1","MultiPlanarReconstructionStyle"],1502:["CS","1","MPRThicknessType"],1503:["FD","1","MPRSlabThickness"],1505:["FD","3","MPRTopLeftHandCorner"],1507:["FD","3","MPRViewWidthDirection"],1508:["FD","1","MPRViewWidth"],"150C":["UL","1","NumberOfVolumetricCurvePoints"],"150D":["OD","1","VolumetricCurvePoints"],1511:["FD","3","MPRViewHeightDirection"],1512:["FD","1","MPRViewHeight"],1602:["CS","1","RenderProjection"],1603:["FD","3","ViewpointPosition"],1604:["FD","3","ViewpointLookAtPoint"],1605:["FD","3","ViewpointUpDirection"],1606:["FD","6","RenderFieldOfView"],1607:["FD","1","SamplingStepSize"],1701:["CS","1","ShadingStyle"],1702:["FD","1","AmbientReflectionIntensity"],1703:["FD","3","LightDirection"],1704:["FD","1","DiffuseReflectionIntensity"],1705:["FD","1","SpecularReflectionIntensity"],1706:["FD","1","Shininess"],1801:["SQ","1","PresentationStateClassificationComponentSequence"],1802:["CS","1","ComponentType"],1803:["SQ","1","ComponentInputSequence"],1804:["US","1","VolumetricPresentationInputIndex"],1805:["SQ","1","PresentationStateCompositorComponentSequence"],1806:["SQ","1","WeightingTransferFunctionSequence"],1807:["US","3","WeightingLookupTableDescriptor"],1808:["OB","1","WeightingLookupTableData"],1901:["SQ","1","VolumetricAnnotationSequence"],1903:["SQ","1","ReferencedStructuredContextSequence"],1904:["UI","1","ReferencedContentItem"],1905:["SQ","1","VolumetricPresentationInputAnnotationSequence"],1907:["CS","1","AnnotationClipping"],"1A01":["CS","1","PresentationAnimationStyle"],"1A03":["FD","1","RecommendedAnimationRate"],"1A04":["SQ","1","AnimationCurveSequence"],"1A05":["FD","1","AnimationStepSize"],"1A06":["FD","1","SwivelRange"],"1A07":["OD","1","VolumetricCurveUpDirections"],"1A08":["SQ","1","VolumeStreamSequence"],"1A09":["LO","1","RGBATransferFunctionDescription"],"1B01":["SQ","1","AdvancedBlendingSequence"],"1B02":["US","1","BlendingInputNumber"],"1B03":["SQ","1","BlendingDisplayInputSequence"],"1B04":["SQ","1","BlendingDisplaySequence"],"1B06":["CS","1","BlendingMode"],"1B07":["CS","1","TimeSeriesBlending"],"1B08":["CS","1","GeometryForDisplay"],"1B11":["SQ","1","ThresholdSequence"],"1B12":["SQ","1","ThresholdValueSequence"],"1B13":["CS","1","ThresholdType"],"1B14":["FD","1","ThresholdValue"]},"0072":{"0000":["UL","1","GenericGroupLength"],"0002":["SH","1","HangingProtocolName"],"0004":["LO","1","HangingProtocolDescription"],"0006":["CS","1","HangingProtocolLevel"],"0008":["LO","1","HangingProtocolCreator"],"000A":["DT","1","HangingProtocolCreationDateTime"],"000C":["SQ","1","HangingProtocolDefinitionSequence"],"000E":["SQ","1","HangingProtocolUserIdentificationCodeSequence"],"0010":["LO","1","HangingProtocolUserGroupName"],"0012":["SQ","1","SourceHangingProtocolSequence"],"0014":["US","1","NumberOfPriorsReferenced"],"0020":["SQ","1","ImageSetsSequence"],"0022":["SQ","1","ImageSetSelectorSequence"],"0024":["CS","1","ImageSetSelectorUsageFlag"],"0026":["AT","1","SelectorAttribute"],"0028":["US","1","SelectorValueNumber"],"0030":["SQ","1","TimeBasedImageSetsSequence"],"0032":["US","1","ImageSetNumber"],"0034":["CS","1","ImageSetSelectorCategory"],"0038":["US","2","RelativeTime"],"003A":["CS","1","RelativeTimeUnits"],"003C":["SS","2","AbstractPriorValue"],"003E":["SQ","1","AbstractPriorCodeSequence"],"0040":["LO","1","ImageSetLabel"],"0050":["CS","1","SelectorAttributeVR"],"0052":["AT","1-n","SelectorSequencePointer"],"0054":["LO","1-n","SelectorSequencePointerPrivateCreator"],"0056":["LO","1","SelectorAttributePrivateCreator"],"005E":["AE","1-n","SelectorAEValue"],"005F":["AS","1-n","SelectorASValue"],"0060":["AT","1-n","SelectorATValue"],"0061":["DA","1-n","SelectorDAValue"],"0062":["CS","1-n","SelectorCSValue"],"0063":["DT","1-n","SelectorDTValue"],"0064":["IS","1-n","SelectorISValue"],"0065":["OB","1","SelectorOBValue"],"0066":["LO","1-n","SelectorLOValue"],"0067":["OF","1","SelectorOFValue"],"0068":["LT","1","SelectorLTValue"],"0069":["OW","1","SelectorOWValue"],"006A":["PN","1-n","SelectorPNValue"],"006B":["TM","1-n","SelectorTMValue"],"006C":["SH","1-n","SelectorSHValue"],"006D":["UN","1","SelectorUNValue"],"006E":["ST","1","SelectorSTValue"],"006F":["UC","1-n","SelectorUCValue"],"0070":["UT","1","SelectorUTValue"],"0071":["UR","1","SelectorURValue"],"0072":["DS","1-n","SelectorDSValue"],"0073":["OD","1","SelectorODValue"],"0074":["FD","1-n","SelectorFDValue"],"0075":["OL","1","SelectorOLValue"],"0076":["FL","1-n","SelectorFLValue"],"0078":["UL","1-n","SelectorULValue"],"007A":["US","1-n","SelectorUSValue"],"007C":["SL","1-n","SelectorSLValue"],"007E":["SS","1-n","SelectorSSValue"],"007F":["UI","1-n","SelectorUIValue"],"0080":["SQ","1","SelectorCodeSequenceValue"],"0081":["OV","1","SelectorOVValue"],"0082":["SV","1-n","SelectorSVValue"],"0083":["UV","1-n","SelectorUVValue"],"0100":["US","1","NumberOfScreens"],"0102":["SQ","1","NominalScreenDefinitionSequence"],"0104":["US","1","NumberOfVerticalPixels"],"0106":["US","1","NumberOfHorizontalPixels"],"0108":["FD","4","DisplayEnvironmentSpatialPosition"],"010A":["US","1","ScreenMinimumGrayscaleBitDepth"],"010C":["US","1","ScreenMinimumColorBitDepth"],"010E":["US","1","ApplicationMaximumRepaintTime"],"0200":["SQ","1","DisplaySetsSequence"],"0202":["US","1","DisplaySetNumber"],"0203":["LO","1","DisplaySetLabel"],"0204":["US","1","DisplaySetPresentationGroup"],"0206":["LO","1","DisplaySetPresentationGroupDescription"],"0208":["CS","1","PartialDataDisplayHandling"],"0210":["SQ","1","SynchronizedScrollingSequence"],"0212":["US","2-n","DisplaySetScrollingGroup"],"0214":["SQ","1","NavigationIndicatorSequence"],"0216":["US","1","NavigationDisplaySet"],"0218":["US","1-n","ReferenceDisplaySets"],"0300":["SQ","1","ImageBoxesSequence"],"0302":["US","1","ImageBoxNumber"],"0304":["CS","1","ImageBoxLayoutType"],"0306":["US","1","ImageBoxTileHorizontalDimension"],"0308":["US","1","ImageBoxTileVerticalDimension"],"0310":["CS","1","ImageBoxScrollDirection"],"0312":["CS","1","ImageBoxSmallScrollType"],"0314":["US","1","ImageBoxSmallScrollAmount"],"0316":["CS","1","ImageBoxLargeScrollType"],"0318":["US","1","ImageBoxLargeScrollAmount"],"0320":["US","1","ImageBoxOverlapPriority"],"0330":["FD","1","CineRelativeToRealTime"],"0400":["SQ","1","FilterOperationsSequence"],"0402":["CS","1","FilterByCategory"],"0404":["CS","1","FilterByAttributePresence"],"0406":["CS","1","FilterByOperator"],"0420":["US","3","StructuredDisplayBackgroundCIELabValue"],"0421":["US","3","EmptyImageBoxCIELabValue"],"0422":["SQ","1","StructuredDisplayImageBoxSequence"],"0424":["SQ","1","StructuredDisplayTextBoxSequence"],"0427":["SQ","1","ReferencedFirstFrameSequence"],"0430":["SQ","1","ImageBoxSynchronizationSequence"],"0432":["US","2-n","SynchronizedImageBoxList"],"0434":["CS","1","TypeOfSynchronization"],"0500":["CS","1","BlendingOperationType"],"0510":["CS","1","ReformattingOperationType"],"0512":["FD","1","ReformattingThickness"],"0514":["FD","1","ReformattingInterval"],"0516":["CS","1","ReformattingOperationInitialViewDirection"],"0520":["CS","1-n","ThreeDRenderingType"],"0600":["SQ","1","SortingOperationsSequence"],"0602":["CS","1","SortByCategory"],"0604":["CS","1","SortingDirection"],"0700":["CS","2","DisplaySetPatientOrientation"],"0702":["CS","1","VOIType"],"0704":["CS","1","PseudoColorType"],"0705":["SQ","1","PseudoColorPaletteInstanceReferenceSequence"],"0706":["CS","1","ShowGrayscaleInverted"],"0710":["CS","1","ShowImageTrueSizeFlag"],"0712":["CS","1","ShowGraphicAnnotationFlag"],"0714":["CS","1","ShowPatientDemographicsFlag"],"0716":["CS","1","ShowAcquisitionTechniquesFlag"],"0717":["CS","1","DisplaySetHorizontalJustification"],"0718":["CS","1","DisplaySetVerticalJustification"]},"0074":{"0000":["UL","1","GenericGroupLength"],"0120":["FD","1","ContinuationStartMeterset"],"0121":["FD","1","ContinuationEndMeterset"],1e3:["CS","1","ProcedureStepState"],1002:["SQ","1","ProcedureStepProgressInformationSequence"],1004:["DS","1","ProcedureStepProgress"],1006:["ST","1","ProcedureStepProgressDescription"],1007:["SQ","1","ProcedureStepProgressParametersSequence"],1008:["SQ","1","ProcedureStepCommunicationsURISequence"],"100A":["UR","1","ContactURI"],"100C":["LO","1","ContactDisplayName"],"100E":["SQ","1","ProcedureStepDiscontinuationReasonCodeSequence"],1020:["SQ","1","BeamTaskSequence"],1022:["CS","1","BeamTaskType"],1024:["IS","1","BeamOrderIndexTrial"],1025:["CS","1","AutosequenceFlag"],1026:["FD","1","TableTopVerticalAdjustedPosition"],1027:["FD","1","TableTopLongitudinalAdjustedPosition"],1028:["FD","1","TableTopLateralAdjustedPosition"],"102A":["FD","1","PatientSupportAdjustedAngle"],"102B":["FD","1","TableTopEccentricAdjustedAngle"],"102C":["FD","1","TableTopPitchAdjustedAngle"],"102D":["FD","1","TableTopRollAdjustedAngle"],1030:["SQ","1","DeliveryVerificationImageSequence"],1032:["CS","1","VerificationImageTiming"],1034:["CS","1","DoubleExposureFlag"],1036:["CS","1","DoubleExposureOrdering"],1038:["DS","1","DoubleExposureMetersetTrial"],"103A":["DS","4","DoubleExposureFieldDeltaTrial"],1040:["SQ","1","RelatedReferenceRTImageSequence"],1042:["SQ","1","GeneralMachineVerificationSequence"],1044:["SQ","1","ConventionalMachineVerificationSequence"],1046:["SQ","1","IonMachineVerificationSequence"],1048:["SQ","1","FailedAttributesSequence"],"104A":["SQ","1","OverriddenAttributesSequence"],"104C":["SQ","1","ConventionalControlPointVerificationSequence"],"104E":["SQ","1","IonControlPointVerificationSequence"],1050:["SQ","1","AttributeOccurrenceSequence"],1052:["AT","1","AttributeOccurrencePointer"],1054:["UL","1","AttributeItemSelector"],1056:["LO","1","AttributeOccurrencePrivateCreator"],1057:["IS","1-n","SelectorSequencePointerItems"],1200:["CS","1","ScheduledProcedureStepPriority"],1202:["LO","1","WorklistLabel"],1204:["LO","1","ProcedureStepLabel"],1210:["SQ","1","ScheduledProcessingParametersSequence"],1212:["SQ","1","PerformedProcessingParametersSequence"],1216:["SQ","1","UnifiedProcedureStepPerformedProcedureSequence"],1220:["SQ","1","RelatedProcedureStepSequence"],1222:["LO","1","ProcedureStepRelationshipType"],1224:["SQ","1","ReplacedProcedureStepSequence"],1230:["LO","1","DeletionLock"],1234:["AE","1","ReceivingAE"],1236:["AE","1","RequestingAE"],1238:["LT","1","ReasonForCancellation"],1242:["CS","1","SCPStatus"],1244:["CS","1","SubscriptionListStatus"],1246:["CS","1","UnifiedProcedureStepListStatus"],1324:["UL","1","BeamOrderIndex"],1338:["FD","1","DoubleExposureMeterset"],"133A":["FD","4","DoubleExposureFieldDelta"],1401:["SQ","1","BrachyTaskSequence"],1402:["DS","1","ContinuationStartTotalReferenceAirKerma"],1403:["DS","1","ContinuationEndTotalReferenceAirKerma"],1404:["IS","1","ContinuationPulseNumber"],1405:["SQ","1","ChannelDeliveryOrderSequence"],1406:["IS","1","ReferencedChannelNumber"],1407:["DS","1","StartCumulativeTimeWeight"],1408:["DS","1","EndCumulativeTimeWeight"],1409:["SQ","1","OmittedChannelSequence"],"140A":["CS","1","ReasonForChannelOmission"],"140B":["LO","1","ReasonForChannelOmissionDescription"],"140C":["IS","1","ChannelDeliveryOrderIndex"],"140D":["SQ","1","ChannelDeliveryContinuationSequence"],"140E":["SQ","1","OmittedApplicationSetupSequence"]},"0076":{"0000":["UL","1","GenericGroupLength"],"0001":["LO","1","ImplantAssemblyTemplateName"],"0003":["LO","1","ImplantAssemblyTemplateIssuer"],"0006":["LO","1","ImplantAssemblyTemplateVersion"],"0008":["SQ","1","ReplacedImplantAssemblyTemplateSequence"],"000A":["CS","1","ImplantAssemblyTemplateType"],"000C":["SQ","1","OriginalImplantAssemblyTemplateSequence"],"000E":["SQ","1","DerivationImplantAssemblyTemplateSequence"],"0010":["SQ","1","ImplantAssemblyTemplateTargetAnatomySequence"],"0020":["SQ","1","ProcedureTypeCodeSequence"],"0030":["LO","1","SurgicalTechnique"],"0032":["SQ","1","ComponentTypesSequence"],"0034":["SQ","1","ComponentTypeCodeSequence"],"0036":["CS","1","ExclusiveComponentType"],"0038":["CS","1","MandatoryComponentType"],"0040":["SQ","1","ComponentSequence"],"0055":["US","1","ComponentID"],"0060":["SQ","1","ComponentAssemblySequence"],"0070":["US","1","Component1ReferencedID"],"0080":["US","1","Component1ReferencedMatingFeatureSetID"],"0090":["US","1","Component1ReferencedMatingFeatureID"],"00A0":["US","1","Component2ReferencedID"],"00B0":["US","1","Component2ReferencedMatingFeatureSetID"],"00C0":["US","1","Component2ReferencedMatingFeatureID"]},"0078":{"0000":["UL","1","GenericGroupLength"],"0001":["LO","1","ImplantTemplateGroupName"],"0010":["ST","1","ImplantTemplateGroupDescription"],"0020":["LO","1","ImplantTemplateGroupIssuer"],"0024":["LO","1","ImplantTemplateGroupVersion"],"0026":["SQ","1","ReplacedImplantTemplateGroupSequence"],"0028":["SQ","1","ImplantTemplateGroupTargetAnatomySequence"],"002A":["SQ","1","ImplantTemplateGroupMembersSequence"],"002E":["US","1","ImplantTemplateGroupMemberID"],"0050":["FD","3","ThreeDImplantTemplateGroupMemberMatchingPoint"],"0060":["FD","9","ThreeDImplantTemplateGroupMemberMatchingAxes"],"0070":["SQ","1","ImplantTemplateGroupMemberMatching2DCoordinatesSequence"],"0090":["FD","2","TwoDImplantTemplateGroupMemberMatchingPoint"],"00A0":["FD","4","TwoDImplantTemplateGroupMemberMatchingAxes"],"00B0":["SQ","1","ImplantTemplateGroupVariationDimensionSequence"],"00B2":["LO","1","ImplantTemplateGroupVariationDimensionName"],"00B4":["SQ","1","ImplantTemplateGroupVariationDimensionRankSequence"],"00B6":["US","1","ReferencedImplantTemplateGroupMemberID"],"00B8":["US","1","ImplantTemplateGroupVariationDimensionRank"]},"0080":{"0000":["UL","1","GenericGroupLength"],"0001":["SQ","1","SurfaceScanAcquisitionTypeCodeSequence"],"0002":["SQ","1","SurfaceScanModeCodeSequence"],"0003":["SQ","1","RegistrationMethodCodeSequence"],"0004":["FD","1","ShotDurationTime"],"0005":["FD","1","ShotOffsetTime"],"0006":["US","1-n","SurfacePointPresentationValueData"],"0007":["US","3-3n","SurfacePointColorCIELabValueData"],"0008":["SQ","1","UVMappingSequence"],"0009":["SH","1","TextureLabel"],"0010":["OF","1","UValueData"],"0011":["OF","1","VValueData"],"0012":["SQ","1","ReferencedTextureSequence"],"0013":["SQ","1","ReferencedSurfaceDataSequence"]},"0082":{"0000":["UL","1","GenericGroupLength"],"0001":["CS","1","AssessmentSummary"],"0003":["UT","1","AssessmentSummaryDescription"],"0004":["SQ","1","AssessedSOPInstanceSequence"],"0005":["SQ","1","ReferencedComparisonSOPInstanceSequence"],"0006":["UL","1","NumberOfAssessmentObservations"],"0007":["SQ","1","AssessmentObservationsSequence"],"0008":["CS","1","ObservationSignificance"],"000A":["UT","1","ObservationDescription"],"000C":["SQ","1","StructuredConstraintObservationSequence"],"0010":["SQ","1","AssessedAttributeValueSequence"],"0016":["LO","1","AssessmentSetID"],"0017":["SQ","1","AssessmentRequesterSequence"],"0018":["LO","1","SelectorAttributeName"],"0019":["LO","1","SelectorAttributeKeyword"],"0021":["SQ","1","AssessmentTypeCodeSequence"],"0022":["SQ","1","ObservationBasisCodeSequence"],"0023":["LO","1","AssessmentLabel"],"0032":["CS","1","ConstraintType"],"0033":["UT","1","SpecificationSelectionGuidance"],"0034":["SQ","1","ConstraintValueSequence"],"0035":["SQ","1","RecommendedDefaultValueSequence"],"0036":["CS","1","ConstraintViolationSignificance"],"0037":["UT","1","ConstraintViolationCondition"],"0038":["CS","1","ModifiableConstraintFlag"]},"0088":{"0000":["UL","1","GenericGroupLength"],"0130":["SH","1","StorageMediaFileSetID"],"0140":["UI","1","StorageMediaFileSetUID"],"0200":["SQ","1","IconImageSequence"],"0904":["LO","1","TopicTitle"],"0906":["ST","1","TopicSubject"],"0910":["LO","1","TopicAuthor"],"0912":["LO","1-32","TopicKeywords"]},"0100":{"0000":["UL","1","GenericGroupLength"],"0410":["CS","1","SOPInstanceStatus"],"0420":["DT","1","SOPAuthorizationDateTime"],"0424":["LT","1","SOPAuthorizationComment"],"0426":["LO","1","AuthorizationEquipmentCertificationNumber"]},"0400":{"0000":["UL","1","GenericGroupLength"],"0005":["US","1","MACIDNumber"],"0010":["UI","1","MACCalculationTransferSyntaxUID"],"0015":["CS","1","MACAlgorithm"],"0020":["AT","1-n","DataElementsSigned"],"0100":["UI","1","DigitalSignatureUID"],"0105":["DT","1","DigitalSignatureDateTime"],"0110":["CS","1","CertificateType"],"0115":["OB","1","CertificateOfSigner"],"0120":["OB","1","Signature"],"0305":["CS","1","CertifiedTimestampType"],"0310":["OB","1","CertifiedTimestamp"],"0315":["FL","1",""],"0401":["SQ","1","DigitalSignaturePurposeCodeSequence"],"0402":["SQ","1","ReferencedDigitalSignatureSequence"],"0403":["SQ","1","ReferencedSOPInstanceMACSequence"],"0404":["OB","1","MAC"],"0500":["SQ","1","EncryptedAttributesSequence"],"0510":["UI","1","EncryptedContentTransferSyntaxUID"],"0520":["OB","1","EncryptedContent"],"0550":["SQ","1","ModifiedAttributesSequence"],"0551":["SQ","1","NonconformingModifiedAttributesSequence"],"0552":["OB","1","NonconformingDataElementValue"],"0561":["SQ","1","OriginalAttributesSequence"],"0562":["DT","1","AttributeModificationDateTime"],"0563":["LO","1","ModifyingSystem"],"0564":["LO","1","SourceOfPreviousValues"],"0565":["CS","1","ReasonForTheAttributeModification"],"0600":["CS","1","InstanceOriginStatus"]},1e3:{"0000":["UL","1","GenericGroupLength"],"0010":["US","3","EscapeTriplet"],"0011":["US","3","RunLengthTriplet"],"0012":["US","1","HuffmanTableSize"],"0013":["US","3","HuffmanTableTriplet"],"0014":["US","1","ShiftTableSize"],"0015":["US","3","ShiftTableTriplet"]},1010:{"0000":["UL","1","GenericGroupLength"],"0004":["US","1-n","ZonalMap"]},2e3:{"0000":["UL","1","GenericGroupLength"],"0010":["IS","1","NumberOfCopies"],"001E":["SQ","1","PrinterConfigurationSequence"],"0020":["CS","1","PrintPriority"],"0030":["CS","1","MediumType"],"0040":["CS","1","FilmDestination"],"0050":["LO","1","FilmSessionLabel"],"0060":["IS","1","MemoryAllocation"],"0061":["IS","1","MaximumMemoryAllocation"],"0062":["CS","1","ColorImagePrintingFlag"],"0063":["CS","1","CollationFlag"],"0065":["CS","1","AnnotationFlag"],"0067":["CS","1","ImageOverlayFlag"],"0069":["CS","1","PresentationLUTFlag"],"006A":["CS","1","ImageBoxPresentationLUTFlag"],"00A0":["US","1","MemoryBitDepth"],"00A1":["US","1","PrintingBitDepth"],"00A2":["SQ","1","MediaInstalledSequence"],"00A4":["SQ","1","OtherMediaAvailableSequence"],"00A8":["SQ","1","SupportedImageDisplayFormatsSequence"],"0500":["SQ","1","ReferencedFilmBoxSequence"],"0510":["SQ","1","ReferencedStoredPrintSequence"]},2010:{"0000":["UL","1","GenericGroupLength"],"0010":["ST","1","ImageDisplayFormat"],"0030":["CS","1","AnnotationDisplayFormatID"],"0040":["CS","1","FilmOrientation"],"0050":["CS","1","FilmSizeID"],"0052":["CS","1","PrinterResolutionID"],"0054":["CS","1","DefaultPrinterResolutionID"],"0060":["CS","1","MagnificationType"],"0080":["CS","1","SmoothingType"],"00A6":["CS","1","DefaultMagnificationType"],"00A7":["CS","1-n","OtherMagnificationTypesAvailable"],"00A8":["CS","1","DefaultSmoothingType"],"00A9":["CS","1-n","OtherSmoothingTypesAvailable"],"0100":["CS","1","BorderDensity"],"0110":["CS","1","EmptyImageDensity"],"0120":["US","1","MinDensity"],"0130":["US","1","MaxDensity"],"0140":["CS","1","Trim"],"0150":["ST","1","ConfigurationInformation"],"0152":["LT","1","ConfigurationInformationDescription"],"0154":["IS","1","MaximumCollatedFilms"],"015E":["US","1","Illumination"],"0160":["US","1","ReflectedAmbientLight"],"0376":["DS","2","PrinterPixelSpacing"],"0500":["SQ","1","ReferencedFilmSessionSequence"],"0510":["SQ","1","ReferencedImageBoxSequence"],"0520":["SQ","1","ReferencedBasicAnnotationBoxSequence"]},2020:{"0000":["UL","1","GenericGroupLength"],"0010":["US","1","ImageBoxPosition"],"0020":["CS","1","Polarity"],"0030":["DS","1","RequestedImageSize"],"0040":["CS","1","RequestedDecimateCropBehavior"],"0050":["CS","1","RequestedResolutionID"],"00A0":["CS","1","RequestedImageSizeFlag"],"00A2":["CS","1","DecimateCropResult"],"0110":["SQ","1","BasicGrayscaleImageSequence"],"0111":["SQ","1","BasicColorImageSequence"],"0130":["SQ","1","ReferencedImageOverlayBoxSequence"],"0140":["SQ","1","ReferencedVOILUTBoxSequence"]},2030:{"0000":["UL","1","GenericGroupLength"],"0010":["US","1","AnnotationPosition"],"0020":["LO","1","TextString"]},2040:{"0000":["UL","1","GenericGroupLength"],"0010":["SQ","1","ReferencedOverlayPlaneSequence"],"0011":["US","1-99","ReferencedOverlayPlaneGroups"],"0020":["SQ","1","OverlayPixelDataSequence"],"0060":["CS","1","OverlayMagnificationType"],"0070":["CS","1","OverlaySmoothingType"],"0072":["CS","1","OverlayOrImageMagnification"],"0074":["US","1","MagnifyToNumberOfColumns"],"0080":["CS","1","OverlayForegroundDensity"],"0082":["CS","1","OverlayBackgroundDensity"],"0090":["CS","1","OverlayMode"],"0100":["CS","1","ThresholdDensity"],"0500":["SQ","1","ReferencedImageBoxSequenceRetired"]},2050:{"0000":["UL","1","GenericGroupLength"],"0010":["SQ","1","PresentationLUTSequence"],"0020":["CS","1","PresentationLUTShape"],"0500":["SQ","1","ReferencedPresentationLUTSequence"]},2100:{"0000":["UL","1","GenericGroupLength"],"0010":["SH","1","PrintJobID"],"0020":["CS","1","ExecutionStatus"],"0030":["CS","1","ExecutionStatusInfo"],"0040":["DA","1","CreationDate"],"0050":["TM","1","CreationTime"],"0070":["AE","1","Originator"],"0140":["AE","1","DestinationAE"],"0160":["SH","1","OwnerID"],"0170":["IS","1","NumberOfFilms"],"0500":["SQ","1","ReferencedPrintJobSequencePullStoredPrint"]},2110:{"0000":["UL","1","GenericGroupLength"],"0010":["CS","1","PrinterStatus"],"0020":["CS","1","PrinterStatusInfo"],"0030":["LO","1","PrinterName"],"0099":["SH","1","PrintQueueID"]},2120:{"0000":["UL","1","GenericGroupLength"],"0010":["CS","1","QueueStatus"],"0050":["SQ","1","PrintJobDescriptionSequence"],"0070":["SQ","1","ReferencedPrintJobSequence"]},2130:{"0000":["UL","1","GenericGroupLength"],"0010":["SQ","1","PrintManagementCapabilitiesSequence"],"0015":["SQ","1","PrinterCharacteristicsSequence"],"0030":["SQ","1","FilmBoxContentSequence"],"0040":["SQ","1","ImageBoxContentSequence"],"0050":["SQ","1","AnnotationContentSequence"],"0060":["SQ","1","ImageOverlayBoxContentSequence"],"0080":["SQ","1","PresentationLUTContentSequence"],"00A0":["SQ","1","ProposedStudySequence"],"00C0":["SQ","1","OriginalImageSequence"]},2200:{"0000":["UL","1","GenericGroupLength"],"0001":["CS","1","LabelUsingInformationExtractedFromInstances"],"0002":["UT","1","LabelText"],"0003":["CS","1","LabelStyleSelection"],"0004":["LT","1","MediaDisposition"],"0005":["LT","1","BarcodeValue"],"0006":["CS","1","BarcodeSymbology"],"0007":["CS","1","AllowMediaSplitting"],"0008":["CS","1","IncludeNonDICOMObjects"],"0009":["CS","1","IncludeDisplayApplication"],"000A":["CS","1","PreserveCompositeInstancesAfterMediaCreation"],"000B":["US","1","TotalNumberOfPiecesOfMediaCreated"],"000C":["LO","1","RequestedMediaApplicationProfile"],"000D":["SQ","1","ReferencedStorageMediaSequence"],"000E":["AT","1-n","FailureAttributes"],"000F":["CS","1","AllowLossyCompression"],"0020":["CS","1","RequestPriority"]},3002:{"0000":["UL","1","GenericGroupLength"],"0002":["SH","1","RTImageLabel"],"0003":["LO","1","RTImageName"],"0004":["ST","1","RTImageDescription"],"000A":["CS","1","ReportedValuesOrigin"],"000C":["CS","1","RTImagePlane"],"000D":["DS","3","XRayImageReceptorTranslation"],"000E":["DS","1","XRayImageReceptorAngle"],"0010":["DS","6","RTImageOrientation"],"0011":["DS","2","ImagePlanePixelSpacing"],"0012":["DS","2","RTImagePosition"],"0020":["SH","1","RadiationMachineName"],"0022":["DS","1","RadiationMachineSAD"],"0024":["DS","1","RadiationMachineSSD"],"0026":["DS","1","RTImageSID"],"0028":["DS","1","SourceToReferenceObjectDistance"],"0029":["IS","1","FractionNumber"],"0030":["SQ","1","ExposureSequence"],"0032":["DS","1","MetersetExposure"],"0034":["DS","4","DiaphragmPosition"],"0040":["SQ","1","FluenceMapSequence"],"0041":["CS","1","FluenceDataSource"],"0042":["DS","1","FluenceDataScale"],"0050":["SQ","1","PrimaryFluenceModeSequence"],"0051":["CS","1","FluenceMode"],"0052":["SH","1","FluenceModeID"]},3004:{"0000":["UL","1","GenericGroupLength"],"0001":["CS","1","DVHType"],"0002":["CS","1","DoseUnits"],"0004":["CS","1","DoseType"],"0005":["CS","1","SpatialTransformOfDose"],"0006":["LO","1","DoseComment"],"0008":["DS","3","NormalizationPoint"],"000A":["CS","1","DoseSummationType"],"000C":["DS","2-n","GridFrameOffsetVector"],"000E":["DS","1","DoseGridScaling"],"0010":["SQ","1","RTDoseROISequence"],"0012":["DS","1","DoseValue"],"0014":["CS","1-3","TissueHeterogeneityCorrection"],"0040":["DS","3","DVHNormalizationPoint"],"0042":["DS","1","DVHNormalizationDoseValue"],"0050":["SQ","1","DVHSequence"],"0052":["DS","1","DVHDoseScaling"],"0054":["CS","1","DVHVolumeUnits"],"0056":["IS","1","DVHNumberOfBins"],"0058":["DS","2-2n","DVHData"],"0060":["SQ","1","DVHReferencedROISequence"],"0062":["CS","1","DVHROIContributionType"],"0070":["DS","1","DVHMinimumDose"],"0072":["DS","1","DVHMaximumDose"],"0074":["DS","1","DVHMeanDose"]},3006:{"0000":["UL","1","GenericGroupLength"],"0002":["SH","1","StructureSetLabel"],"0004":["LO","1","StructureSetName"],"0006":["ST","1","StructureSetDescription"],"0008":["DA","1","StructureSetDate"],"0009":["TM","1","StructureSetTime"],"0010":["SQ","1","ReferencedFrameOfReferenceSequence"],"0012":["SQ","1","RTReferencedStudySequence"],"0014":["SQ","1","RTReferencedSeriesSequence"],"0016":["SQ","1","ContourImageSequence"],"0018":["SQ","1","PredecessorStructureSetSequence"],"0020":["SQ","1","StructureSetROISequence"],"0022":["IS","1","ROINumber"],"0024":["UI","1","ReferencedFrameOfReferenceUID"],"0026":["LO","1","ROIName"],"0028":["ST","1","ROIDescription"],"002A":["IS","3","ROIDisplayColor"],"002C":["DS","1","ROIVolume"],"0030":["SQ","1","RTRelatedROISequence"],"0033":["CS","1","RTROIRelationship"],"0036":["CS","1","ROIGenerationAlgorithm"],"0037":["SQ","1","ROIDerivationAlgorithmIdentificationSequence"],"0038":["LO","1","ROIGenerationDescription"],"0039":["SQ","1","ROIContourSequence"],"0040":["SQ","1","ContourSequence"],"0042":["CS","1","ContourGeometricType"],"0044":["DS","1","ContourSlabThickness"],"0045":["DS","3","ContourOffsetVector"],"0046":["IS","1","NumberOfContourPoints"],"0048":["IS","1","ContourNumber"],"0049":["IS","1-n","AttachedContours"],"004A":["SQ","1","SourcePixelPlanesCharacteristicsSequence"],"0050":["DS","3-3n","ContourData"],"0080":["SQ","1","RTROIObservationsSequence"],"0082":["IS","1","ObservationNumber"],"0084":["IS","1","ReferencedROINumber"],"0085":["SH","1","ROIObservationLabel"],"0086":["SQ","1","RTROIIdentificationCodeSequence"],"0088":["ST","1","ROIObservationDescription"],"00A0":["SQ","1","RelatedRTROIObservationsSequence"],"00A4":["CS","1","RTROIInterpretedType"],"00A6":["PN","1","ROIInterpreter"],"00B0":["SQ","1","ROIPhysicalPropertiesSequence"],"00B2":["CS","1","ROIPhysicalProperty"],"00B4":["DS","1","ROIPhysicalPropertyValue"],"00B6":["SQ","1","ROIElementalCompositionSequence"],"00B7":["US","1","ROIElementalCompositionAtomicNumber"],"00B8":["FL","1","ROIElementalCompositionAtomicMassFraction"],"00B9":["SQ","1","AdditionalRTROIIdentificationCodeSequence"],"00C0":["SQ","1","FrameOfReferenceRelationshipSequence"],"00C2":["UI","1","RelatedFrameOfReferenceUID"],"00C4":["CS","1","FrameOfReferenceTransformationType"],"00C6":["DS","16","FrameOfReferenceTransformationMatrix"],"00C8":["LO","1","FrameOfReferenceTransformationComment"],"00C9":["SQ","1","PatientLocationCoordinatesSequence"],"00CA":["SQ","1","PatientLocationCoordinatesCodeSequence"],"00CB":["SQ","1","PatientSupportPositionSequence"]},3008:{"0000":["UL","1","GenericGroupLength"],"0010":["SQ","1","MeasuredDoseReferenceSequence"],"0012":["ST","1","MeasuredDoseDescription"],"0014":["CS","1","MeasuredDoseType"],"0016":["DS","1","MeasuredDoseValue"],"0020":["SQ","1","TreatmentSessionBeamSequence"],"0021":["SQ","1","TreatmentSessionIonBeamSequence"],"0022":["IS","1","CurrentFractionNumber"],"0024":["DA","1","TreatmentControlPointDate"],"0025":["TM","1","TreatmentControlPointTime"],"002A":["CS","1","TreatmentTerminationStatus"],"002B":["SH","1","TreatmentTerminationCode"],"002C":["CS","1","TreatmentVerificationStatus"],"0030":["SQ","1","ReferencedTreatmentRecordSequence"],"0032":["DS","1","SpecifiedPrimaryMeterset"],"0033":["DS","1","SpecifiedSecondaryMeterset"],"0036":["DS","1","DeliveredPrimaryMeterset"],"0037":["DS","1","DeliveredSecondaryMeterset"],"003A":["DS","1","SpecifiedTreatmentTime"],"003B":["DS","1","DeliveredTreatmentTime"],"0040":["SQ","1","ControlPointDeliverySequence"],"0041":["SQ","1","IonControlPointDeliverySequence"],"0042":["DS","1","SpecifiedMeterset"],"0044":["DS","1","DeliveredMeterset"],"0045":["FL","1","MetersetRateSet"],"0046":["FL","1","MetersetRateDelivered"],"0047":["FL","1-n","ScanSpotMetersetsDelivered"],"0048":["DS","1","DoseRateDelivered"],"0050":["SQ","1","TreatmentSummaryCalculatedDoseReferenceSequence"],"0052":["DS","1","CumulativeDoseToDoseReference"],"0054":["DA","1","FirstTreatmentDate"],"0056":["DA","1","MostRecentTreatmentDate"],"005A":["IS","1","NumberOfFractionsDelivered"],"0060":["SQ","1","OverrideSequence"],"0061":["AT","1","ParameterSequencePointer"],"0062":["AT","1","OverrideParameterPointer"],"0063":["IS","1","ParameterItemIndex"],"0064":["IS","1","MeasuredDoseReferenceNumber"],"0065":["AT","1","ParameterPointer"],"0066":["ST","1","OverrideReason"],"0067":["US","1","ParameterValueNumber"],"0068":["SQ","1","CorrectedParameterSequence"],"006A":["FL","1","CorrectionValue"],"0070":["SQ","1","CalculatedDoseReferenceSequence"],"0072":["IS","1","CalculatedDoseReferenceNumber"],"0074":["ST","1","CalculatedDoseReferenceDescription"],"0076":["DS","1","CalculatedDoseReferenceDoseValue"],"0078":["DS","1","StartMeterset"],"007A":["DS","1","EndMeterset"],"0080":["SQ","1","ReferencedMeasuredDoseReferenceSequence"],"0082":["IS","1","ReferencedMeasuredDoseReferenceNumber"],"0090":["SQ","1","ReferencedCalculatedDoseReferenceSequence"],"0092":["IS","1","ReferencedCalculatedDoseReferenceNumber"],"00A0":["SQ","1","BeamLimitingDeviceLeafPairsSequence"],"00B0":["SQ","1","RecordedWedgeSequence"],"00C0":["SQ","1","RecordedCompensatorSequence"],"00D0":["SQ","1","RecordedBlockSequence"],"00D1":["SQ","1","RecordedBlockSlabSequence"],"00E0":["SQ","1","TreatmentSummaryMeasuredDoseReferenceSequence"],"00F0":["SQ","1","RecordedSnoutSequence"],"00F2":["SQ","1","RecordedRangeShifterSequence"],"00F4":["SQ","1","RecordedLateralSpreadingDeviceSequence"],"00F6":["SQ","1","RecordedRangeModulatorSequence"],"0100":["SQ","1","RecordedSourceSequence"],"0105":["LO","1","SourceSerialNumber"],"0110":["SQ","1","TreatmentSessionApplicationSetupSequence"],"0116":["CS","1","ApplicationSetupCheck"],"0120":["SQ","1","RecordedBrachyAccessoryDeviceSequence"],"0122":["IS","1","ReferencedBrachyAccessoryDeviceNumber"],"0130":["SQ","1","RecordedChannelSequence"],"0132":["DS","1","SpecifiedChannelTotalTime"],"0134":["DS","1","DeliveredChannelTotalTime"],"0136":["IS","1","SpecifiedNumberOfPulses"],"0138":["IS","1","DeliveredNumberOfPulses"],"013A":["DS","1","SpecifiedPulseRepetitionInterval"],"013C":["DS","1","DeliveredPulseRepetitionInterval"],"0140":["SQ","1","RecordedSourceApplicatorSequence"],"0142":["IS","1","ReferencedSourceApplicatorNumber"],"0150":["SQ","1","RecordedChannelShieldSequence"],"0152":["IS","1","ReferencedChannelShieldNumber"],"0160":["SQ","1","BrachyControlPointDeliveredSequence"],"0162":["DA","1","SafePositionExitDate"],"0164":["TM","1","SafePositionExitTime"],"0166":["DA","1","SafePositionReturnDate"],"0168":["TM","1","SafePositionReturnTime"],"0171":["SQ","1","PulseSpecificBrachyControlPointDeliveredSequence"],"0172":["US","1","PulseNumber"],"0173":["SQ","1","BrachyPulseControlPointDeliveredSequence"],"0200":["CS","1","CurrentTreatmentStatus"],"0202":["ST","1","TreatmentStatusComment"],"0220":["SQ","1","FractionGroupSummarySequence"],"0223":["IS","1","ReferencedFractionNumber"],"0224":["CS","1","FractionGroupType"],"0230":["CS","1","BeamStopperPosition"],"0240":["SQ","1","FractionStatusSummarySequence"],"0250":["DA","1","TreatmentDate"],"0251":["TM","1","TreatmentTime"]},"300A":{"0000":["UL","1","GenericGroupLength"],"0002":["SH","1","RTPlanLabel"],"0003":["LO","1","RTPlanName"],"0004":["ST","1","RTPlanDescription"],"0006":["DA","1","RTPlanDate"],"0007":["TM","1","RTPlanTime"],"0009":["LO","1-n","TreatmentProtocols"],"000A":["CS","1","PlanIntent"],"000B":["LO","1-n","TreatmentSites"],"000C":["CS","1","RTPlanGeometry"],"000E":["ST","1","PrescriptionDescription"],"0010":["SQ","1","DoseReferenceSequence"],"0012":["IS","1","DoseReferenceNumber"],"0013":["UI","1","DoseReferenceUID"],"0014":["CS","1","DoseReferenceStructureType"],"0015":["CS","1","NominalBeamEnergyUnit"],"0016":["LO","1","DoseReferenceDescription"],"0018":["DS","3","DoseReferencePointCoordinates"],"001A":["DS","1","NominalPriorDose"],"0020":["CS","1","DoseReferenceType"],"0021":["DS","1","ConstraintWeight"],"0022":["DS","1","DeliveryWarningDose"],"0023":["DS","1","DeliveryMaximumDose"],"0025":["DS","1","TargetMinimumDose"],"0026":["DS","1","TargetPrescriptionDose"],"0027":["DS","1","TargetMaximumDose"],"0028":["DS","1","TargetUnderdoseVolumeFraction"],"002A":["DS","1","OrganAtRiskFullVolumeDose"],"002B":["DS","1","OrganAtRiskLimitDose"],"002C":["DS","1","OrganAtRiskMaximumDose"],"002D":["DS","1","OrganAtRiskOverdoseVolumeFraction"],"0040":["SQ","1","ToleranceTableSequence"],"0042":["IS","1","ToleranceTableNumber"],"0043":["SH","1","ToleranceTableLabel"],"0044":["DS","1","GantryAngleTolerance"],"0046":["DS","1","BeamLimitingDeviceAngleTolerance"],"0048":["SQ","1","BeamLimitingDeviceToleranceSequence"],"004A":["DS","1","BeamLimitingDevicePositionTolerance"],"004B":["FL","1","SnoutPositionTolerance"],"004C":["DS","1","PatientSupportAngleTolerance"],"004E":["DS","1","TableTopEccentricAngleTolerance"],"004F":["FL","1","TableTopPitchAngleTolerance"],"0050":["FL","1","TableTopRollAngleTolerance"],"0051":["DS","1","TableTopVerticalPositionTolerance"],"0052":["DS","1","TableTopLongitudinalPositionTolerance"],"0053":["DS","1","TableTopLateralPositionTolerance"],"0055":["CS","1","RTPlanRelationship"],"0070":["SQ","1","FractionGroupSequence"],"0071":["IS","1","FractionGroupNumber"],"0072":["LO","1","FractionGroupDescription"],"0078":["IS","1","NumberOfFractionsPlanned"],"0079":["IS","1","NumberOfFractionPatternDigitsPerDay"],"007A":["IS","1","RepeatFractionCycleLength"],"007B":["LT","1","FractionPattern"],"0080":["IS","1","NumberOfBeams"],"0082":["DS","3","BeamDoseSpecificationPoint"],"0083":["UI","1","ReferencedDoseReferenceUID"],"0084":["DS","1","BeamDose"],"0086":["DS","1","BeamMeterset"],"0088":["FL","1","BeamDosePointDepth"],"0089":["FL","1","BeamDosePointEquivalentDepth"],"008A":["FL","1","BeamDosePointSSD"],"008B":["CS","1","BeamDoseMeaning"],"008C":["SQ","1","BeamDoseVerificationControlPointSequence"],"008D":["FL","1","AverageBeamDosePointDepth"],"008E":["FL","1","AverageBeamDosePointEquivalentDepth"],"008F":["FL","1","AverageBeamDosePointSSD"],"0090":["CS","1","BeamDoseType"],"0091":["DS","1","AlternateBeamDose"],"0092":["CS","1","AlternateBeamDoseType"],"0093":["CS","1","DepthValueAveragingFlag"],"0094":["DS","1","BeamDosePointSourceToExternalContourDistance"],"00A0":["IS","1","NumberOfBrachyApplicationSetups"],"00A2":["DS","3","BrachyApplicationSetupDoseSpecificationPoint"],"00A4":["DS","1","BrachyApplicationSetupDose"],"00B0":["SQ","1","BeamSequence"],"00B2":["SH","1","TreatmentMachineName"],"00B3":["CS","1","PrimaryDosimeterUnit"],"00B4":["DS","1","SourceAxisDistance"],"00B6":["SQ","1","BeamLimitingDeviceSequence"],"00B8":["CS","1","RTBeamLimitingDeviceType"],"00BA":["DS","1","SourceToBeamLimitingDeviceDistance"],"00BB":["FL","1","IsocenterToBeamLimitingDeviceDistance"],"00BC":["IS","1","NumberOfLeafJawPairs"],"00BE":["DS","3-n","LeafPositionBoundaries"],"00C0":["IS","1","BeamNumber"],"00C2":["LO","1","BeamName"],"00C3":["ST","1","BeamDescription"],"00C4":["CS","1","BeamType"],"00C5":["FD","1","BeamDeliveryDurationLimit"],"00C6":["CS","1","RadiationType"],"00C7":["CS","1","HighDoseTechniqueType"],"00C8":["IS","1","ReferenceImageNumber"],"00CA":["SQ","1","PlannedVerificationImageSequence"],"00CC":["LO","1-n","ImagingDeviceSpecificAcquisitionParameters"],"00CE":["CS","1","TreatmentDeliveryType"],"00D0":["IS","1","NumberOfWedges"],"00D1":["SQ","1","WedgeSequence"],"00D2":["IS","1","WedgeNumber"],"00D3":["CS","1","WedgeType"],"00D4":["SH","1","WedgeID"],"00D5":["IS","1","WedgeAngle"],"00D6":["DS","1","WedgeFactor"],"00D7":["FL","1","TotalWedgeTrayWaterEquivalentThickness"],"00D8":["DS","1","WedgeOrientation"],"00D9":["FL","1","IsocenterToWedgeTrayDistance"],"00DA":["DS","1","SourceToWedgeTrayDistance"],"00DB":["FL","1","WedgeThinEdgePosition"],"00DC":["SH","1","BolusID"],"00DD":["ST","1","BolusDescription"],"00DE":["DS","1","EffectiveWedgeAngle"],"00E0":["IS","1","NumberOfCompensators"],"00E1":["SH","1","MaterialID"],"00E2":["DS","1","TotalCompensatorTrayFactor"],"00E3":["SQ","1","CompensatorSequence"],"00E4":["IS","1","CompensatorNumber"],"00E5":["SH","1","CompensatorID"],"00E6":["DS","1","SourceToCompensatorTrayDistance"],"00E7":["IS","1","CompensatorRows"],"00E8":["IS","1","CompensatorColumns"],"00E9":["DS","2","CompensatorPixelSpacing"],"00EA":["DS","2","CompensatorPosition"],"00EB":["DS","1-n","CompensatorTransmissionData"],"00EC":["DS","1-n","CompensatorThicknessData"],"00ED":["IS","1","NumberOfBoli"],"00EE":["CS","1","CompensatorType"],"00EF":["SH","1","CompensatorTrayID"],"00F0":["IS","1","NumberOfBlocks"],"00F2":["DS","1","TotalBlockTrayFactor"],"00F3":["FL","1","TotalBlockTrayWaterEquivalentThickness"],"00F4":["SQ","1","BlockSequence"],"00F5":["SH","1","BlockTrayID"],"00F6":["DS","1","SourceToBlockTrayDistance"],"00F7":["FL","1","IsocenterToBlockTrayDistance"],"00F8":["CS","1","BlockType"],"00F9":["LO","1","AccessoryCode"],"00FA":["CS","1","BlockDivergence"],"00FB":["CS","1","BlockMountingPosition"],"00FC":["IS","1","BlockNumber"],"00FE":["LO","1","BlockName"],"0100":["DS","1","BlockThickness"],"0102":["DS","1","BlockTransmission"],"0104":["IS","1","BlockNumberOfPoints"],"0106":["DS","2-2n","BlockData"],"0107":["SQ","1","ApplicatorSequence"],"0108":["SH","1","ApplicatorID"],"0109":["CS","1","ApplicatorType"],"010A":["LO","1","ApplicatorDescription"],"010C":["DS","1","CumulativeDoseReferenceCoefficient"],"010E":["DS","1","FinalCumulativeMetersetWeight"],"0110":["IS","1","NumberOfControlPoints"],"0111":["SQ","1","ControlPointSequence"],"0112":["IS","1","ControlPointIndex"],"0114":["DS","1","NominalBeamEnergy"],"0115":["DS","1","DoseRateSet"],"0116":["SQ","1","WedgePositionSequence"],"0118":["CS","1","WedgePosition"],"011A":["SQ","1","BeamLimitingDevicePositionSequence"],"011C":["DS","2-2n","LeafJawPositions"],"011E":["DS","1","GantryAngle"],"011F":["CS","1","GantryRotationDirection"],"0120":["DS","1","BeamLimitingDeviceAngle"],"0121":["CS","1","BeamLimitingDeviceRotationDirection"],"0122":["DS","1","PatientSupportAngle"],"0123":["CS","1","PatientSupportRotationDirection"],"0124":["DS","1","TableTopEccentricAxisDistance"],"0125":["DS","1","TableTopEccentricAngle"],"0126":["CS","1","TableTopEccentricRotationDirection"],"0128":["DS","1","TableTopVerticalPosition"],"0129":["DS","1","TableTopLongitudinalPosition"],"012A":["DS","1","TableTopLateralPosition"],"012C":["DS","3","IsocenterPosition"],"012E":["DS","3","SurfaceEntryPoint"],"0130":["DS","1","SourceToSurfaceDistance"],"0131":["FL","1","AverageBeamDosePointSourceToExternalContourDistance"],"0132":["FL","1","SourceToExternalContourDistance"],"0133":["FL","3","ExternalContourEntryPoint"],"0134":["DS","1","CumulativeMetersetWeight"],"0140":["FL","1","TableTopPitchAngle"],"0142":["CS","1","TableTopPitchRotationDirection"],"0144":["FL","1","TableTopRollAngle"],"0146":["CS","1","TableTopRollRotationDirection"],"0148":["FL","1","HeadFixationAngle"],"014A":["FL","1","GantryPitchAngle"],"014C":["CS","1","GantryPitchRotationDirection"],"014E":["FL","1","GantryPitchAngleTolerance"],"0150":["CS","1","FixationEye"],"0151":["DS","1","ChairHeadFramePosition"],"0152":["DS","1","HeadFixationAngleTolerance"],"0153":["DS","1","ChairHeadFramePositionTolerance"],"0154":["DS","1","FixationLightAzimuthalAngleTolerance"],"0155":["DS","1","FixationLightPolarAngleTolerance"],"0180":["SQ","1","PatientSetupSequence"],"0182":["IS","1","PatientSetupNumber"],"0183":["LO","1","PatientSetupLabel"],"0184":["LO","1","PatientAdditionalPosition"],"0190":["SQ","1","FixationDeviceSequence"],"0192":["CS","1","FixationDeviceType"],"0194":["SH","1","FixationDeviceLabel"],"0196":["ST","1","FixationDeviceDescription"],"0198":["SH","1","FixationDevicePosition"],"0199":["FL","1","FixationDevicePitchAngle"],"019A":["FL","1","FixationDeviceRollAngle"],"01A0":["SQ","1","ShieldingDeviceSequence"],"01A2":["CS","1","ShieldingDeviceType"],"01A4":["SH","1","ShieldingDeviceLabel"],"01A6":["ST","1","ShieldingDeviceDescription"],"01A8":["SH","1","ShieldingDevicePosition"],"01B0":["CS","1","SetupTechnique"],"01B2":["ST","1","SetupTechniqueDescription"],"01B4":["SQ","1","SetupDeviceSequence"],"01B6":["CS","1","SetupDeviceType"],"01B8":["SH","1","SetupDeviceLabel"],"01BA":["ST","1","SetupDeviceDescription"],"01BC":["DS","1","SetupDeviceParameter"],"01D0":["ST","1","SetupReferenceDescription"],"01D2":["DS","1","TableTopVerticalSetupDisplacement"],"01D4":["DS","1","TableTopLongitudinalSetupDisplacement"],"01D6":["DS","1","TableTopLateralSetupDisplacement"],"0200":["CS","1","BrachyTreatmentTechnique"],"0202":["CS","1","BrachyTreatmentType"],"0206":["SQ","1","TreatmentMachineSequence"],"0210":["SQ","1","SourceSequence"],"0212":["IS","1","SourceNumber"],"0214":["CS","1","SourceType"],"0216":["LO","1","SourceManufacturer"],"0218":["DS","1","ActiveSourceDiameter"],"021A":["DS","1","ActiveSourceLength"],"021B":["SH","1","SourceModelID"],"021C":["LO","1","SourceDescription"],"0222":["DS","1","SourceEncapsulationNominalThickness"],"0224":["DS","1","SourceEncapsulationNominalTransmission"],"0226":["LO","1","SourceIsotopeName"],"0228":["DS","1","SourceIsotopeHalfLife"],"0229":["CS","1","SourceStrengthUnits"],"022A":["DS","1","ReferenceAirKermaRate"],"022B":["DS","1","SourceStrength"],"022C":["DA","1","SourceStrengthReferenceDate"],"022E":["TM","1","SourceStrengthReferenceTime"],"0230":["SQ","1","ApplicationSetupSequence"],"0232":["CS","1","ApplicationSetupType"],"0234":["IS","1","ApplicationSetupNumber"],"0236":["LO","1","ApplicationSetupName"],"0238":["LO","1","ApplicationSetupManufacturer"],"0240":["IS","1","TemplateNumber"],"0242":["SH","1","TemplateType"],"0244":["LO","1","TemplateName"],"0250":["DS","1","TotalReferenceAirKerma"],"0260":["SQ","1","BrachyAccessoryDeviceSequence"],"0262":["IS","1","BrachyAccessoryDeviceNumber"],"0263":["SH","1","BrachyAccessoryDeviceID"],"0264":["CS","1","BrachyAccessoryDeviceType"],"0266":["LO","1","BrachyAccessoryDeviceName"],"026A":["DS","1","BrachyAccessoryDeviceNominalThickness"],"026C":["DS","1","BrachyAccessoryDeviceNominalTransmission"],"0271":["DS","1","ChannelEffectiveLength"],"0272":["DS","1","ChannelInnerLength"],"0273":["SH","1","AfterloaderChannelID"],"0274":["DS","1","SourceApplicatorTipLength"],"0280":["SQ","1","ChannelSequence"],"0282":["IS","1","ChannelNumber"],"0284":["DS","1","ChannelLength"],"0286":["DS","1","ChannelTotalTime"],"0288":["CS","1","SourceMovementType"],"028A":["IS","1","NumberOfPulses"],"028C":["DS","1","PulseRepetitionInterval"],"0290":["IS","1","SourceApplicatorNumber"],"0291":["SH","1","SourceApplicatorID"],"0292":["CS","1","SourceApplicatorType"],"0294":["LO","1","SourceApplicatorName"],"0296":["DS","1","SourceApplicatorLength"],"0298":["LO","1","SourceApplicatorManufacturer"],"029C":["DS","1","SourceApplicatorWallNominalThickness"],"029E":["DS","1","SourceApplicatorWallNominalTransmission"],"02A0":["DS","1","SourceApplicatorStepSize"],"02A1":["IS","1","ApplicatorShapeReferencedROINumber"],"02A2":["IS","1","TransferTubeNumber"],"02A4":["DS","1","TransferTubeLength"],"02B0":["SQ","1","ChannelShieldSequence"],"02B2":["IS","1","ChannelShieldNumber"],"02B3":["SH","1","ChannelShieldID"],"02B4":["LO","1","ChannelShieldName"],"02B8":["DS","1","ChannelShieldNominalThickness"],"02BA":["DS","1","ChannelShieldNominalTransmission"],"02C8":["DS","1","FinalCumulativeTimeWeight"],"02D0":["SQ","1","BrachyControlPointSequence"],"02D2":["DS","1","ControlPointRelativePosition"],"02D4":["DS","3","ControlPoint3DPosition"],"02D6":["DS","1","CumulativeTimeWeight"],"02E0":["CS","1","CompensatorDivergence"],"02E1":["CS","1","CompensatorMountingPosition"],"02E2":["DS","1-n","SourceToCompensatorDistance"],"02E3":["FL","1","TotalCompensatorTrayWaterEquivalentThickness"],"02E4":["FL","1","IsocenterToCompensatorTrayDistance"],"02E5":["FL","1","CompensatorColumnOffset"],"02E6":["FL","1-n","IsocenterToCompensatorDistances"],"02E7":["FL","1","CompensatorRelativeStoppingPowerRatio"],"02E8":["FL","1","CompensatorMillingToolDiameter"],"02EA":["SQ","1","IonRangeCompensatorSequence"],"02EB":["LT","1","CompensatorDescription"],"0302":["IS","1","RadiationMassNumber"],"0304":["IS","1","RadiationAtomicNumber"],"0306":["SS","1","RadiationChargeState"],"0308":["CS","1","ScanMode"],"0309":["CS","1","ModulatedScanModeType"],"030A":["FL","2","VirtualSourceAxisDistances"],"030C":["SQ","1","SnoutSequence"],"030D":["FL","1","SnoutPosition"],"030F":["SH","1","SnoutID"],"0312":["IS","1","NumberOfRangeShifters"],"0314":["SQ","1","RangeShifterSequence"],"0316":["IS","1","RangeShifterNumber"],"0318":["SH","1","RangeShifterID"],"0320":["CS","1","RangeShifterType"],"0322":["LO","1","RangeShifterDescription"],"0330":["IS","1","NumberOfLateralSpreadingDevices"],"0332":["SQ","1","LateralSpreadingDeviceSequence"],"0334":["IS","1","LateralSpreadingDeviceNumber"],"0336":["SH","1","LateralSpreadingDeviceID"],"0338":["CS","1","LateralSpreadingDeviceType"],"033A":["LO","1","LateralSpreadingDeviceDescription"],"033C":["FL","1","LateralSpreadingDeviceWaterEquivalentThickness"],"0340":["IS","1","NumberOfRangeModulators"],"0342":["SQ","1","RangeModulatorSequence"],"0344":["IS","1","RangeModulatorNumber"],"0346":["SH","1","RangeModulatorID"],"0348":["CS","1","RangeModulatorType"],"034A":["LO","1","RangeModulatorDescription"],"034C":["SH","1","BeamCurrentModulationID"],"0350":["CS","1","PatientSupportType"],"0352":["SH","1","PatientSupportID"],"0354":["LO","1","PatientSupportAccessoryCode"],"0355":["LO","1","TrayAccessoryCode"],"0356":["FL","1","FixationLightAzimuthalAngle"],"0358":["FL","1","FixationLightPolarAngle"],"035A":["FL","1","MetersetRate"],"0360":["SQ","1","RangeShifterSettingsSequence"],"0362":["LO","1","RangeShifterSetting"],"0364":["FL","1","IsocenterToRangeShifterDistance"],"0366":["FL","1","RangeShifterWaterEquivalentThickness"],"0370":["SQ","1","LateralSpreadingDeviceSettingsSequence"],"0372":["LO","1","LateralSpreadingDeviceSetting"],"0374":["FL","1","IsocenterToLateralSpreadingDeviceDistance"],"0380":["SQ","1","RangeModulatorSettingsSequence"],"0382":["FL","1","RangeModulatorGatingStartValue"],"0384":["FL","1","RangeModulatorGatingStopValue"],"0386":["FL","1","RangeModulatorGatingStartWaterEquivalentThickness"],"0388":["FL","1","RangeModulatorGatingStopWaterEquivalentThickness"],"038A":["FL","1","IsocenterToRangeModulatorDistance"],"038F":["FL","1-n","ScanSpotTimeOffset"],"0390":["SH","1","ScanSpotTuneID"],"0391":["IS","1-n","ScanSpotPrescribedIndices"],"0392":["IS","1","NumberOfScanSpotPositions"],"0393":["CS","1","ScanSpotReordered"],"0394":["FL","1-n","ScanSpotPositionMap"],"0395":["CS","1","ScanSpotReorderingAllowed"],"0396":["FL","1-n","ScanSpotMetersetWeights"],"0398":["FL","2","ScanningSpotSize"],"0399":["FL","2-2n","ScanSpotSizesDelivered"],"039A":["IS","1","NumberOfPaintings"],"03A0":["SQ","1","IonToleranceTableSequence"],"03A2":["SQ","1","IonBeamSequence"],"03A4":["SQ","1","IonBeamLimitingDeviceSequence"],"03A6":["SQ","1","IonBlockSequence"],"03A8":["SQ","1","IonControlPointSequence"],"03AA":["SQ","1","IonWedgeSequence"],"03AC":["SQ","1","IonWedgePositionSequence"],"0401":["SQ","1","ReferencedSetupImageSequence"],"0402":["ST","1","SetupImageComment"],"0410":["SQ","1","MotionSynchronizationSequence"],"0412":["FL","3","ControlPointOrientation"],"0420":["SQ","1","GeneralAccessorySequence"],"0421":["SH","1","GeneralAccessoryID"],"0422":["ST","1","GeneralAccessoryDescription"],"0423":["CS","1","GeneralAccessoryType"],"0424":["IS","1","GeneralAccessoryNumber"],"0425":["FL","1","SourceToGeneralAccessoryDistance"],"0426":["DS","1","IsocenterToGeneralAccessoryDistance"],"0431":["SQ","1","ApplicatorGeometrySequence"],"0432":["CS","1","ApplicatorApertureShape"],"0433":["FL","1","ApplicatorOpening"],"0434":["FL","1","ApplicatorOpeningX"],"0435":["FL","1","ApplicatorOpeningY"],"0436":["FL","1","SourceToApplicatorMountingPositionDistance"],"0440":["IS","1","NumberOfBlockSlabItems"],"0441":["SQ","1","BlockSlabSequence"],"0442":["DS","1","BlockSlabThickness"],"0443":["US","1","BlockSlabNumber"],"0450":["SQ","1","DeviceMotionControlSequence"],"0451":["CS","1","DeviceMotionExecutionMode"],"0452":["CS","1","DeviceMotionObservationMode"],"0453":["SQ","1","DeviceMotionParameterCodeSequence"],"0501":["FL","1","DistalDepthFraction"],"0502":["FL","1","DistalDepth"],"0503":["FL","2","NominalRangeModulationFractions"],"0504":["FL","2","NominalRangeModulatedRegionDepths"],"0505":["SQ","1","DepthDoseParametersSequence"],"0506":["SQ","1","DeliveredDepthDoseParametersSequence"],"0507":["FL","1","DeliveredDistalDepthFraction"],"0508":["FL","1","DeliveredDistalDepth"],"0509":["FL","2","DeliveredNominalRangeModulationFractions"],"0510":["FL","2","DeliveredNominalRangeModulatedRegionDepths"],"0511":["CS","1","DeliveredReferenceDoseDefinition"],"0512":["CS","1","ReferenceDoseDefinition"],"0600":["US","1","RTControlPointIndex"],"0601":["US","1","RadiationGenerationModeIndex"],"0602":["US","1","ReferencedDefinedDeviceIndex"],"0603":["US","1","RadiationDoseIdentificationIndex"],"0604":["US","1","NumberOfRTControlPoints"],"0605":["US","1","ReferencedRadiationGenerationModeIndex"],"0606":["US","1","TreatmentPositionIndex"],"0607":["US","1","ReferencedDeviceIndex"],"0608":["LO","1","TreatmentPositionGroupLabel"],"0609":["UI","1","TreatmentPositionGroupUID"],"060A":["SQ","1","TreatmentPositionGroupSequence"],"060B":["US","1","ReferencedTreatmentPositionIndex"],"060C":["US","1","ReferencedRadiationDoseIdentificationIndex"],"060D":["FD","1","RTAccessoryHolderWaterEquivalentThickness"],"060E":["US","1","ReferencedRTAccessoryHolderDeviceIndex"],"060F":["CS","1","RTAccessoryHolderSlotExistenceFlag"],"0610":["SQ","1","RTAccessoryHolderSlotSequence"],"0611":["LO","1","RTAccessoryHolderSlotID"],"0612":["FD","1","RTAccessoryHolderSlotDistance"],"0613":["FD","1","RTAccessorySlotDistance"],"0614":["SQ","1","RTAccessoryHolderDefinitionSequence"],"0615":["LO","1","RTAccessoryDeviceSlotID"],"0616":["SQ","1","RTRadiationSequence"],"0617":["SQ","1","RadiationDoseSequence"],"0618":["SQ","1","RadiationDoseIdentificationSequence"],"0619":["LO","1","RadiationDoseIdentificationLabel"],"061A":["CS","1","ReferenceDoseType"],"061B":["CS","1","PrimaryDoseValueIndicator"],"061C":["SQ","1","DoseValuesSequence"],"061D":["CS","1-n","DoseValuePurpose"],"061E":["FD","3","ReferenceDosePointCoordinates"],"061F":["SQ","1","RadiationDoseValuesParametersSequence"],"0620":["SQ","1","MetersetToDoseMappingSequence"],"0621":["SQ","1","ExpectedInVivoMeasurementValuesSequence"],"0622":["US","1","ExpectedInVivoMeasurementValueIndex"],"0623":["LO","1","RadiationDoseInVivoMeasurementLabel"],"0624":["FD","2","RadiationDoseCentralAxisDisplacement"],"0625":["FD","1","RadiationDoseValue"],"0626":["FD","1","RadiationDoseSourceToSkinDistance"],"0627":["FD","3","RadiationDoseMeasurementPointCoordinates"],"0628":["FD","1","RadiationDoseSourceToExternalContourDistance"],"0629":["SQ","1","RTToleranceSetSequence"],"062A":["LO","1","RTToleranceSetLabel"],"062B":["SQ","1","AttributeToleranceValuesSequence"],"062C":["FD","1","ToleranceValue"],"062D":["SQ","1","PatientSupportPositionToleranceSequence"],"062E":["FD","1","TreatmentTimeLimit"],"062F":["SQ","1","CArmPhotonElectronControlPointSequence"],"0630":["SQ","1","ReferencedRTRadiationSequence"],"0631":["SQ","1","ReferencedRTInstanceSequence"],"0632":["SQ","1","ReferencedRTPatientSetupSequence"],"0634":["FD","1","SourceToPatientSurfaceDistance"],"0635":["SQ","1","TreatmentMachineSpecialModeCodeSequence"],"0636":["US","1","IntendedNumberOfFractions"],"0637":["CS","1","RTRadiationSetIntent"],"0638":["CS","1","RTRadiationPhysicalAndGeometricContentDetailFlag"],"0639":["CS","1","RTRecordFlag"],"063A":["SQ","1","TreatmentDeviceIdentificationSequence"],"063B":["SQ","1","ReferencedRTPhysicianIntentSequence"],"063C":["FD","1","CumulativeMeterset"],"063D":["FD","1","DeliveryRate"],"063E":["SQ","1","DeliveryRateUnitSequence"],"063F":["SQ","1","TreatmentPositionSequence"],"0640":["FD","1","RadiationSourceAxisDistance"],"0641":["US","1","NumberOfRTBeamLimitingDevices"],"0642":["FD","1","RTBeamLimitingDeviceProximalDistance"],"0643":["FD","1","RTBeamLimitingDeviceDistalDistance"],"0644":["SQ","1","ParallelRTBeamDelimiterDeviceOrientationLabelCodeSequence"],"0645":["FD","1","BeamModifierOrientationAngle"],"0646":["SQ","1","FixedRTBeamDelimiterDeviceSequence"],"0647":["SQ","1","ParallelRTBeamDelimiterDeviceSequence"],"0648":["US","1","NumberOfParallelRTBeamDelimiters"],"0649":["FD","2-n","ParallelRTBeamDelimiterBoundaries"],"064A":["FD","2-n","ParallelRTBeamDelimiterPositions"],"064B":["FD","2","RTBeamLimitingDeviceOffset"],"064C":["SQ","1","RTBeamDelimiterGeometrySequence"],"064D":["SQ","1","RTBeamLimitingDeviceDefinitionSequence"],"064E":["CS","1","ParallelRTBeamDelimiterOpeningMode"],"064F":["CS","1-n","ParallelRTBeamDelimiterLeafMountingSide"],"0650":["UI","1","PatientSetupUID"],"0651":["SQ","1","WedgeDefinitionSequence"],"0652":["FD","1","RadiationBeamWedgeAngle"],"0653":["FD","1","RadiationBeamWedgeThinEdgeDistance"],"0654":["FD","1","RadiationBeamEffectiveWedgeAngle"],"0655":["US","1","NumberOfWedgePositions"],"0656":["SQ","1","RTBeamLimitingDeviceOpeningSequence"],"0657":["US","1","NumberOfRTBeamLimitingDeviceOpenings"],"0658":["SQ","1","RadiationDosimeterUnitSequence"],"0659":["SQ","1","RTDeviceDistanceReferenceLocationCodeSequence"],"065A":["SQ","1","RadiationDeviceConfigurationAndCommissioningKeySequence"],"065B":["SQ","1","PatientSupportPositionParameterSequence"],"065C":["CS","1","PatientSupportPositionSpecificationMethod"],"065D":["SQ","1","PatientSupportPositionDeviceParameterSequence"],"065E":["US","1","DeviceOrderIndex"],"065F":["US","1","PatientSupportPositionParameterOrderIndex"],"0660":["SQ","1","PatientSupportPositionDeviceToleranceSequence"],"0661":["US","1","PatientSupportPositionToleranceOrderIndex"],"0662":["SQ","1","CompensatorDefinitionSequence"],"0663":["CS","1","CompensatorMapOrientation"],"0664":["OF","1","CompensatorProximalThicknessMap"],"0665":["OF","1","CompensatorDistalThicknessMap"],"0666":["FD","1","CompensatorBasePlaneOffset"],"0667":["SQ","1","CompensatorShapeFabricationCodeSequence"],"0668":["SQ","1","CompensatorShapeSequence"],"0669":["FD","1","RadiationBeamCompensatorMillingToolDiameter"],"066A":["SQ","1","BlockDefinitionSequence"],"066B":["OF","1","BlockEdgeData"],"066C":["CS","1","BlockOrientation"],"066D":["FD","1","RadiationBeamBlockThickness"],"066E":["FD","1","RadiationBeamBlockSlabThickness"],"066F":["SQ","1","BlockEdgeDataSequence"],"0670":["US","1","NumberOfRTAccessoryHolders"],"0671":["SQ","1","GeneralAccessoryDefinitionSequence"],"0672":["US","1","NumberOfGeneralAccessories"],"0673":["SQ","1","BolusDefinitionSequence"],"0674":["US","1","NumberOfBoluses"],"0675":["UI","1","EquipmentFrameOfReferenceUID"],"0676":["ST","1","EquipmentFrameOfReferenceDescription"],"0677":["SQ","1","EquipmentReferencePointCoordinatesSequence"],"0678":["SQ","1","EquipmentReferencePointCodeSequence"],"0679":["FD","1","RTBeamLimitingDeviceAngle"],"067A":["FD","1","SourceRollAngle"],"067B":["SQ","1","RadiationGenerationModeSequence"],"067C":["SH","1","RadiationGenerationModeLabel"],"067D":["ST","1","RadiationGenerationModeDescription"],"067E":["SQ","1","RadiationGenerationModeMachineCodeSequence"],"067F":["SQ","1","RadiationTypeCodeSequence"],"0680":["DS","1","NominalEnergy"],"0681":["DS","1","MinimumNominalEnergy"],"0682":["DS","1","MaximumNominalEnergy"],"0683":["SQ","1","RadiationFluenceModifierCodeSequence"],"0684":["SQ","1","EnergyUnitCodeSequence"],"0685":["US","1","NumberOfRadiationGenerationModes"],"0686":["SQ","1","PatientSupportDevicesSequence"],"0687":["US","1","NumberOfPatientSupportDevices"],"0688":["FD","1","RTBeamModifierDefinitionDistance"],"0689":["SQ","1","BeamAreaLimitSequence"],"068A":["SQ","1","ReferencedRTPrescriptionSequence"],"0700":["UI","1","TreatmentSessionUID"],"0701":["CS","1","RTRadiationUsage"],"0702":["SQ","1","ReferencedRTRadiationSetSequence"],"0703":["SQ","1","ReferencedRTRadiationRecordSequence"],"0704":["US","1","RTRadiationSetDeliveryNumber"],"0705":["US","1","ClinicalFractionNumber"],"0706":["CS","1","RTTreatmentFractionCompletionStatus"],"0707":["CS","1","RTRadiationSetUsage"],"0708":["CS","1","TreatmentDeliveryContinuationFlag"],"0709":["CS","1","TreatmentRecordContentOrigin"],"0714":["CS","1","RTTreatmentTerminationStatus"],"0715":["SQ","1","RTTreatmentTerminationReasonCodeSequence"],"0716":["SQ","1","MachineSpecificTreatmentTerminationCodeSequence"],"0722":["SQ","1","RTRadiationSalvageRecordControlPointSequence"],"0723":["CS","1","StartingMetersetValueKnownFlag"],"0730":["ST","1","TreatmentTerminationDescription"],"0731":["SQ","1","TreatmentToleranceViolationSequence"],"0732":["CS","1","TreatmentToleranceViolationCategory"],"0733":["SQ","1","TreatmentToleranceViolationAttributeSequence"],"0734":["ST","1","TreatmentToleranceViolationDescription"],"0735":["ST","1","TreatmentToleranceViolationIdentification"],"0736":["DT","1","TreatmentToleranceViolationDateTime"],"073A":["DT","1","RecordedRTControlPointDateTime"],"073B":["US","1","ReferencedRadiationRTControlPointIndex"],"073E":["SQ","1","AlternateValueSequence"],"073F":["SQ","1","ConfirmationSequence"],"0740":["SQ","1","InterlockSequence"],"0741":["DT","1","InterlockDateTime"],"0742":["ST","1","InterlockDescription"],"0743":["SQ","1","InterlockOriginatingDeviceSequence"],"0744":["SQ","1","InterlockCodeSequence"],"0745":["SQ","1","InterlockResolutionCodeSequence"],"0746":["SQ","1","InterlockResolutionUserSequence"],"0760":["DT","1","OverrideDateTime"],"0761":["SQ","1","TreatmentToleranceViolationTypeCodeSequence"],"0762":["SQ","1","TreatmentToleranceViolationCauseCodeSequence"],"0772":["SQ","1","MeasuredMetersetToDoseMappingSequence"],"0773":["US","1","ReferencedExpectedInVivoMeasurementValueIndex"],"0774":["SQ","1","DoseMeasurementDeviceCodeSequence"],"0780":["SQ","1","AdditionalParameterRecordingInstanceSequence"],"0782":["US","1",""],"0783":["ST","1","InterlockOriginDescription"],"0784":["SQ","1","RTPatientPositionScopeSequence"],"0785":["UI","1","ReferencedTreatmentPositionGroupUID"],"0786":["US","1","RadiationOrderIndex"],"0787":["SQ","1","OmittedRadiationSequence"],"0788":["SQ","1","ReasonForOmissionCodeSequence"],"0789":["SQ","1","RTDeliveryStartPatientPositionSequence"],"078A":["SQ","1","RTTreatmentPreparationPatientPositionSequence"],"078B":["SQ","1","ReferencedRTTreatmentPreparationSequence"],"078C":["SQ","1","ReferencedPatientSetupPhotoSequence"],"078D":["SQ","1","PatientTreatmentPreparationMethodCodeSequence"],"078E":["LT","1","PatientTreatmentPreparationProcedureParameterDescription"],"078F":["SQ","1","PatientTreatmentPreparationDeviceSequence"],"0790":["SQ","1","PatientTreatmentPreparationProcedureSequence"],"0791":["SQ","1","PatientTreatmentPreparationProcedureCodeSequence"],"0792":["LT","1","PatientTreatmentPreparationMethodDescription"],"0793":["SQ","1","PatientTreatmentPreparationProcedureParameterSequence"],"0794":["LT","1","PatientSetupPhotoDescription"],"0795":["US","1","PatientTreatmentPreparationProcedureIndex"],"0796":["US","1","ReferencedPatientSetupProcedureIndex"],"0797":["SQ","1","RTRadiationTaskSequence"],"0798":["SQ","1","RTPatientPositionDisplacementSequence"],"0799":["SQ","1","RTPatientPositionSequence"],"079A":["LO","1","DisplacementReferenceLabel"],"079B":["FD","16","DisplacementMatrix"],"079C":["SQ","1","PatientSupportDisplacementSequence"],"079D":["SQ","1","DisplacementReferenceLocationCodeSequence"],"079E":["CS","1","RTRadiationSetDeliveryUsage"]},"300C":{"0000":["UL","1","GenericGroupLength"],"0002":["SQ","1","ReferencedRTPlanSequence"],"0004":["SQ","1","ReferencedBeamSequence"],"0006":["IS","1","ReferencedBeamNumber"],"0007":["IS","1","ReferencedReferenceImageNumber"],"0008":["DS","1","StartCumulativeMetersetWeight"],"0009":["DS","1","EndCumulativeMetersetWeight"],"000A":["SQ","1","ReferencedBrachyApplicationSetupSequence"],"000C":["IS","1","ReferencedBrachyApplicationSetupNumber"],"000E":["IS","1","ReferencedSourceNumber"],"0020":["SQ","1","ReferencedFractionGroupSequence"],"0022":["IS","1","ReferencedFractionGroupNumber"],"0040":["SQ","1","ReferencedVerificationImageSequence"],"0042":["SQ","1","ReferencedReferenceImageSequence"],"0050":["SQ","1","ReferencedDoseReferenceSequence"],"0051":["IS","1","ReferencedDoseReferenceNumber"],"0055":["SQ","1","BrachyReferencedDoseReferenceSequence"],"0060":["SQ","1","ReferencedStructureSetSequence"],"006A":["IS","1","ReferencedPatientSetupNumber"],"0080":["SQ","1","ReferencedDoseSequence"],"00A0":["IS","1","ReferencedToleranceTableNumber"],"00B0":["SQ","1","ReferencedBolusSequence"],"00C0":["IS","1","ReferencedWedgeNumber"],"00D0":["IS","1","ReferencedCompensatorNumber"],"00E0":["IS","1","ReferencedBlockNumber"],"00F0":["IS","1","ReferencedControlPointIndex"],"00F2":["SQ","1","ReferencedControlPointSequence"],"00F4":["IS","1","ReferencedStartControlPointIndex"],"00F6":["IS","1","ReferencedStopControlPointIndex"],"0100":["IS","1","ReferencedRangeShifterNumber"],"0102":["IS","1","ReferencedLateralSpreadingDeviceNumber"],"0104":["IS","1","ReferencedRangeModulatorNumber"],"0111":["SQ","1","OmittedBeamTaskSequence"],"0112":["CS","1","ReasonForOmission"],"0113":["LO","1","ReasonForOmissionDescription"],"0114":["SQ","1","PrescriptionOverviewSequence"],"0115":["FL","1","TotalPrescriptionDose"],"0116":["SQ","1","PlanOverviewSequence"],"0117":["US","1","PlanOverviewIndex"],"0118":["US","1","ReferencedPlanOverviewIndex"],"0119":["US","1","NumberOfFractionsIncluded"],"0120":["SQ","1","DoseCalibrationConditionsSequence"],"0121":["FD","1","AbsorbedDoseToMetersetRatio"],"0122":["FD","2","DelineatedRadiationFieldSize"],"0123":["CS","1","DoseCalibrationConditionsVerifiedFlag"],"0124":["FD","1","CalibrationReferencePointDepth"],"0125":["SQ","1","GatingBeamHoldTransitionSequence"],"0126":["CS","1","BeamHoldTransition"],"0127":["DT","1","BeamHoldTransitionDateTime"],"0128":["SQ","1","BeamHoldOriginatingDeviceSequence"]},"300E":{"0000":["UL","1","GenericGroupLength"],"0002":["CS","1","ApprovalStatus"],"0004":["DA","1","ReviewDate"],"0005":["TM","1","ReviewTime"],"0008":["PN","1","ReviewerName"]},3010:{"0000":["UL","1","GenericGroupLength"],"0001":["SQ","1","RadiobiologicalDoseEffectSequence"],"0002":["CS","1","RadiobiologicalDoseEffectFlag"],"0003":["SQ","1","EffectiveDoseCalculationMethodCategoryCodeSequence"],"0004":["SQ","1","EffectiveDoseCalculationMethodCodeSequence"],"0005":["LO","1","EffectiveDoseCalculationMethodDescription"],"0006":["UI","1","ConceptualVolumeUID"],"0007":["SQ","1","OriginatingSOPInstanceReferenceSequence"],"0008":["SQ","1","ConceptualVolumeConstituentSequence"],"0009":["SQ","1","EquivalentConceptualVolumeInstanceReferenceSequence"],"000A":["SQ","1","EquivalentConceptualVolumesSequence"],"000B":["UI","1","ReferencedConceptualVolumeUID"],"000C":["UT","1","ConceptualVolumeCombinationExpression"],"000D":["US","1","ConceptualVolumeConstituentIndex"],"000E":["CS","1","ConceptualVolumeCombinationFlag"],"000F":["ST","1","ConceptualVolumeCombinationDescription"],"0010":["CS","1","ConceptualVolumeSegmentationDefinedFlag"],"0011":["SQ","1","ConceptualVolumeSegmentationReferenceSequence"],"0012":["SQ","1","ConceptualVolumeConstituentSegmentationReferenceSequence"],"0013":["UI","1","ConstituentConceptualVolumeUID"],"0014":["SQ","1","DerivationConceptualVolumeSequence"],"0015":["UI","1","SourceConceptualVolumeUID"],"0016":["SQ","1","ConceptualVolumeDerivationAlgorithmSequence"],"0017":["ST","1","ConceptualVolumeDescription"],"0018":["SQ","1","SourceConceptualVolumeSequence"],"0019":["SQ","1","AuthorIdentificationSequence"],"001A":["LO","1","ManufacturerModelVersion"],"001B":["UC","1","DeviceAlternateIdentifier"],"001C":["CS","1","DeviceAlternateIdentifierType"],"001D":["LT","1","DeviceAlternateIdentifierFormat"],"001E":["LO","1","SegmentationCreationTemplateLabel"],"001F":["UI","1","SegmentationTemplateUID"],"0020":["US","1","ReferencedSegmentReferenceIndex"],"0021":["SQ","1","SegmentReferenceSequence"],"0022":["US","1","SegmentReferenceIndex"],"0023":["SQ","1","DirectSegmentReferenceSequence"],"0024":["SQ","1","CombinationSegmentReferenceSequence"],"0025":["SQ","1","ConceptualVolumeSequence"],"0026":["SQ","1","SegmentedRTAccessoryDeviceSequence"],"0027":["SQ","1","SegmentCharacteristicsSequence"],"0028":["SQ","1","RelatedSegmentCharacteristicsSequence"],"0029":["US","1","SegmentCharacteristicsPrecedence"],"002A":["SQ","1","RTSegmentAnnotationSequence"],"002B":["SQ","1","SegmentAnnotationCategoryCodeSequence"],"002C":["SQ","1","SegmentAnnotationTypeCodeSequence"],"002D":["LO","1","DeviceLabel"],"002E":["SQ","1","DeviceTypeCodeSequence"],"002F":["SQ","1","SegmentAnnotationTypeModifierCodeSequence"],"0030":["SQ","1","PatientEquipmentRelationshipCodeSequence"],"0031":["UI","1","ReferencedFiducialsUID"],"0032":["SQ","1","PatientTreatmentOrientationSequence"],"0033":["SH","1","UserContentLabel"],"0034":["LO","1","UserContentLongLabel"],"0035":["SH","1","EntityLabel"],"0036":["LO","1","EntityName"],"0037":["ST","1","EntityDescription"],"0038":["LO","1","EntityLongLabel"],"0039":["US","1","DeviceIndex"],"003A":["US","1","RTTreatmentPhaseIndex"],"003B":["UI","1","RTTreatmentPhaseUID"],"003C":["US","1","RTPrescriptionIndex"],"003D":["US","1","RTSegmentAnnotationIndex"],"003E":["US","1","BasisRTTreatmentPhaseIndex"],"003F":["US","1","RelatedRTTreatmentPhaseIndex"],"0040":["US","1","ReferencedRTTreatmentPhaseIndex"],"0041":["US","1","ReferencedRTPrescriptionIndex"],"0042":["US","1","ReferencedParentRTPrescriptionIndex"],"0043":["ST","1","ManufacturerDeviceIdentifier"],"0044":["SQ","1","InstanceLevelReferencedPerformedProcedureStepSequence"],"0045":["CS","1","RTTreatmentPhaseIntentPresenceFlag"],"0046":["CS","1","RadiotherapyTreatmentType"],"0047":["CS","1-n","TeletherapyRadiationType"],"0048":["CS","1-n","BrachytherapySourceType"],"0049":["SQ","1","ReferencedRTTreatmentPhaseSequence"],"004A":["SQ","1","ReferencedDirectSegmentInstanceSequence"],"004B":["SQ","1","IntendedRTTreatmentPhaseSequence"],"004C":["DA","1","IntendedPhaseStartDate"],"004D":["DA","1","IntendedPhaseEndDate"],"004E":["SQ","1","RTTreatmentPhaseIntervalSequence"],"004F":["CS","1","TemporalRelationshipIntervalAnchor"],"0050":["FD","1","MinimumNumberOfIntervalDays"],"0051":["FD","1","MaximumNumberOfIntervalDays"],"0052":["UI","1-n","PertinentSOPClassesInStudy"],"0053":["UI","1-n","PertinentSOPClassesInSeries"],"0054":["LO","1","RTPrescriptionLabel"],"0055":["SQ","1","RTPhysicianIntentPredecessorSequence"],"0056":["LO","1","RTTreatmentApproachLabel"],"0057":["SQ","1","RTPhysicianIntentSequence"],"0058":["US","1","RTPhysicianIntentIndex"],"0059":["CS","1","RTTreatmentIntentType"],"005A":["UT","1","RTPhysicianIntentNarrative"],"005B":["SQ","1","RTProtocolCodeSequence"],"005C":["ST","1","ReasonForSuperseding"],"005D":["SQ","1","RTDiagnosisCodeSequence"],"005E":["US","1","ReferencedRTPhysicianIntentIndex"],"005F":["SQ","1","RTPhysicianIntentInputInstanceSequence"],"0060":["SQ","1","RTAnatomicPrescriptionSequence"],"0061":["UT","1","PriorTreatmentDoseDescription"],"0062":["SQ","1","PriorTreatmentReferenceSequence"],"0063":["CS","1","DosimetricObjectiveEvaluationScope"],"0064":["SQ","1","TherapeuticRoleCategoryCodeSequence"],"0065":["SQ","1","TherapeuticRoleTypeCodeSequence"],"0066":["US","1","ConceptualVolumeOptimizationPrecedence"],"0067":["SQ","1","ConceptualVolumeCategoryCodeSequence"],"0068":["CS","1","ConceptualVolumeBlockingConstraint"],"0069":["SQ","1","ConceptualVolumeTypeCodeSequence"],"006A":["SQ","1","ConceptualVolumeTypeModifierCodeSequence"],"006B":["SQ","1","RTPrescriptionSequence"],"006C":["SQ","1","DosimetricObjectiveSequence"],"006D":["SQ","1","DosimetricObjectiveTypeCodeSequence"],"006E":["UI","1","DosimetricObjectiveUID"],"006F":["UI","1","ReferencedDosimetricObjectiveUID"],"0070":["SQ","1","DosimetricObjectiveParameterSequence"],"0071":["SQ","1","ReferencedDosimetricObjectivesSequence"],"0073":["CS","1","AbsoluteDosimetricObjectiveFlag"],"0074":["FD","1","DosimetricObjectiveWeight"],"0075":["CS","1","DosimetricObjectivePurpose"],"0076":["SQ","1","PlanningInputInformationSequence"],"0077":["LO","1","TreatmentSite"],"0078":["SQ","1","TreatmentSiteCodeSequence"],"0079":["SQ","1","FractionPatternSequence"],"007A":["UT","1","TreatmentTechniqueNotes"],"007B":["UT","1","PrescriptionNotes"],"007C":["IS","1","NumberOfIntervalFractions"],"007D":["US","1","NumberOfFractions"],"007E":["US","1","IntendedDeliveryDuration"],"007F":["UT","1","FractionationNotes"],"0080":["SQ","1","RTTreatmentTechniqueCodeSequence"],"0081":["SQ","1","PrescriptionNotesSequence"],"0082":["SQ","1","FractionBasedRelationshipSequence"],"0083":["CS","1","FractionBasedRelationshipIntervalAnchor"],"0084":["FD","1","MinimumHoursBetweenFractions"],"0085":["TM","1-n","IntendedFractionStartTime"],"0086":["LT","1","IntendedStartDayOfWeek"],"0087":["SQ","1","WeekdayFractionPatternSequence"],"0088":["SQ","1","DeliveryTimeStructureCodeSequence"],"0089":["SQ","1","TreatmentSiteModifierCodeSequence"],"0090":["CS","1","RoboticBaseLocationIndicator"],"0091":["SQ","1","RoboticPathNodeSetCodeSequence"],"0092":["UL","1","RoboticNodeIdentifier"],"0093":["FD","3","RTTreatmentSourceCoordinates"],"0094":["FD","1","RadiationSourceCoordinateSystemYawAngle"],"0095":["FD","1","RadiationSourceCoordinateSystemRollAngle"],"0096":["FD","1","RadiationSourceCoordinateSystemPitchAngle"],"0097":["SQ","1","RoboticPathControlPointSequence"],"0098":["SQ","1","TomotherapeuticControlPointSequence"],"0099":["FD","1-n","TomotherapeuticLeafOpenDurations"],"009A":["FD","1-n","TomotherapeuticLeafInitialClosedDurations"]},4e3:{"0000":["UL","1","GenericGroupLength"],"0010":["LT","1","Arbitrary"],4e3:["LT","1","TextComments"]},4008:{"0000":["UL","1","GenericGroupLength"],"0040":["SH","1","ResultsID"],"0042":["LO","1","ResultsIDIssuer"],"0050":["SQ","1","ReferencedInterpretationSequence"],"00FF":["CS","1","ReportProductionStatusTrial"],"0100":["DA","1","InterpretationRecordedDate"],"0101":["TM","1","InterpretationRecordedTime"],"0102":["PN","1","InterpretationRecorder"],"0103":["LO","1","ReferenceToRecordedSound"],"0108":["DA","1","InterpretationTranscriptionDate"],"0109":["TM","1","InterpretationTranscriptionTime"],"010A":["PN","1","InterpretationTranscriber"],"010B":["ST","1","InterpretationText"],"010C":["PN","1","InterpretationAuthor"],"0111":["SQ","1","InterpretationApproverSequence"],"0112":["DA","1","InterpretationApprovalDate"],"0113":["TM","1","InterpretationApprovalTime"],"0114":["PN","1","PhysicianApprovingInterpretation"],"0115":["LT","1","InterpretationDiagnosisDescription"],"0117":["SQ","1","InterpretationDiagnosisCodeSequence"],"0118":["SQ","1","ResultsDistributionListSequence"],"0119":["PN","1","DistributionName"],"011A":["LO","1","DistributionAddress"],"0200":["SH","1","InterpretationID"],"0202":["LO","1","InterpretationIDIssuer"],"0210":["CS","1","InterpretationTypeID"],"0212":["CS","1","InterpretationStatusID"],"0300":["ST","1","Impressions"],4e3:["ST","1","ResultsComments"]},4010:{"0000":["UL","1","GenericGroupLength"],"0001":["CS","1","LowEnergyDetectors"],"0002":["CS","1","HighEnergyDetectors"],"0004":["SQ","1","DetectorGeometrySequence"],1001:["SQ","1","ThreatROIVoxelSequence"],1004:["FL","3","ThreatROIBase"],1005:["FL","3","ThreatROIExtents"],1006:["OB","1","ThreatROIBitmap"],1007:["SH","1","RouteSegmentID"],1008:["CS","1","GantryType"],1009:["CS","1","OOIOwnerType"],"100A":["SQ","1","RouteSegmentSequence"],1010:["US","1","PotentialThreatObjectID"],1011:["SQ","1","ThreatSequence"],1012:["CS","1","ThreatCategory"],1013:["LT","1","ThreatCategoryDescription"],1014:["CS","1","ATDAbilityAssessment"],1015:["CS","1","ATDAssessmentFlag"],1016:["FL","1","ATDAssessmentProbability"],1017:["FL","1","Mass"],1018:["FL","1","Density"],1019:["FL","1","ZEffective"],"101A":["SH","1","BoardingPassID"],"101B":["FL","3","CenterOfMass"],"101C":["FL","3","CenterOfPTO"],"101D":["FL","6-n","BoundingPolygon"],"101E":["SH","1","RouteSegmentStartLocationID"],"101F":["SH","1","RouteSegmentEndLocationID"],1020:["CS","1","RouteSegmentLocationIDType"],1021:["CS","1-n","AbortReason"],1023:["FL","1","VolumeOfPTO"],1024:["CS","1","AbortFlag"],1025:["DT","1","RouteSegmentStartTime"],1026:["DT","1","RouteSegmentEndTime"],1027:["CS","1","TDRType"],1028:["CS","1","InternationalRouteSegment"],1029:["LO","1-n","ThreatDetectionAlgorithmAndVersion"],"102A":["SH","1","AssignedLocation"],"102B":["DT","1","AlarmDecisionTime"],1031:["CS","1","AlarmDecision"],1033:["US","1","NumberOfTotalObjects"],1034:["US","1","NumberOfAlarmObjects"],1037:["SQ","1","PTORepresentationSequence"],1038:["SQ","1","ATDAssessmentSequence"],1039:["CS","1","TIPType"],"103A":["CS","1","DICOSVersion"],1041:["DT","1","OOIOwnerCreationTime"],1042:["CS","1","OOIType"],1043:["FL","3","OOISize"],1044:["CS","1","AcquisitionStatus"],1045:["SQ","1","BasisMaterialsCodeSequence"],1046:["CS","1","PhantomType"],1047:["SQ","1","OOIOwnerSequence"],1048:["CS","1","ScanType"],1051:["LO","1","ItineraryID"],1052:["SH","1","ItineraryIDType"],1053:["LO","1","ItineraryIDAssigningAuthority"],1054:["SH","1","RouteID"],1055:["SH","1","RouteIDAssigningAuthority"],1056:["CS","1","InboundArrivalType"],1058:["SH","1","CarrierID"],1059:["CS","1","CarrierIDAssigningAuthority"],1060:["FL","3","SourceOrientation"],1061:["FL","3","SourcePosition"],1062:["FL","1","BeltHeight"],1064:["SQ","1","AlgorithmRoutingCodeSequence"],1067:["CS","1","TransportClassification"],1068:["LT","1","OOITypeDescriptor"],1069:["FL","1","TotalProcessingTime"],"106C":["OB","1","DetectorCalibrationData"],"106D":["CS","1","AdditionalScreeningPerformed"],"106E":["CS","1","AdditionalInspectionSelectionCriteria"],"106F":["SQ","1","AdditionalInspectionMethodSequence"],1070:["CS","1","AITDeviceType"],1071:["SQ","1","QRMeasurementsSequence"],1072:["SQ","1","TargetMaterialSequence"],1073:["FD","1","SNRThreshold"],1075:["DS","1","ImageScaleRepresentation"],1076:["SQ","1","ReferencedPTOSequence"],1077:["SQ","1","ReferencedTDRInstanceSequence"],1078:["ST","1","PTOLocationDescription"],1079:["SQ","1","AnomalyLocatorIndicatorSequence"],"107A":["FL","3","AnomalyLocatorIndicator"],"107B":["SQ","1","PTORegionSequence"],"107C":["CS","1","InspectionSelectionCriteria"],"107D":["SQ","1","SecondaryInspectionMethodSequence"],"107E":["DS","6","PRCSToRCSOrientation"]},"4FFE":{"0000":["UL","1","GenericGroupLength"],"0001":["SQ","1","MACParametersSequence"]},5e3:{"0000":["UL","1","GenericGroupLength"],"0005":["US","1","CurveDimensions"],"0010":["US","1","NumberOfPoints"],"0020":["CS","1","TypeOfData"],"0022":["LO","1","CurveDescription"],"0030":["SH","1-n","AxisUnits"],"0040":["SH","1-n","AxisLabels"],"0103":["US","1","DataValueRepresentation"],"0104":["US","1-n","MinimumCoordinateValue"],"0105":["US","1-n","MaximumCoordinateValue"],"0106":["SH","1-n","CurveRange"],"0110":["US","1-n","CurveDataDescriptor"],"0112":["US","1-n","CoordinateStartValue"],"0114":["US","1-n","CoordinateStepValue"],1001:["CS","1","CurveActivationLayer"],2e3:["US","1","AudioType"],2002:["US","1","AudioSampleFormat"],2004:["US","1","NumberOfChannels"],2006:["UL","1","NumberOfSamples"],2008:["UL","1","SampleRate"],"200A":["UL","1","TotalTime"],"200C":["ox","1","AudioSampleData"],"200E":["LT","1","AudioComments"],2500:["LO","1","CurveLabel"],2600:["SQ","1","CurveReferencedOverlaySequence"],2610:["US","1","CurveReferencedOverlayGroup"],3e3:["ox","1","CurveData"]},5200:{"0000":["UL","1","GenericGroupLength"],9229:["SQ","1","SharedFunctionalGroupsSequence"],9230:["SQ","1","PerFrameFunctionalGroupsSequence"]},5400:{"0000":["UL","1","GenericGroupLength"],"0100":["SQ","1","WaveformSequence"],"0110":["ox","1","ChannelMinimumValue"],"0112":["ox","1","ChannelMaximumValue"],1004:["US","1","WaveformBitsAllocated"],1006:["CS","1","WaveformSampleInterpretation"],"100A":["ox","1","WaveformPaddingValue"],1010:["ox","1","WaveformData"]},5600:{"0000":["UL","1","GenericGroupLength"],"0010":["OF","1","FirstOrderPhaseCorrectionAngle"],"0020":["OF","1","SpectroscopyData"]},6e3:{"0000":["UL","1","GenericGroupLength"],"0010":["US","1","OverlayRows"],"0011":["US","1","OverlayColumns"],"0012":["US","1","OverlayPlanes"],"0015":["IS","1","NumberOfFramesInOverlay"],"0022":["LO","1","OverlayDescription"],"0040":["CS","1","OverlayType"],"0045":["LO","1","OverlaySubtype"],"0050":["SS","2","OverlayOrigin"],"0051":["US","1","ImageFrameOrigin"],"0052":["US","1","OverlayPlaneOrigin"],"0060":["CS","1","OverlayCompressionCode"],"0061":["SH","1","OverlayCompressionOriginator"],"0062":["SH","1","OverlayCompressionLabel"],"0063":["CS","1","OverlayCompressionDescription"],"0066":["AT","1-n","OverlayCompressionStepPointers"],"0068":["US","1","OverlayRepeatInterval"],"0069":["US","1","OverlayBitsGrouped"],"0100":["US","1","OverlayBitsAllocated"],"0102":["US","1","OverlayBitPosition"],"0110":["CS","1","OverlayFormat"],"0200":["US","1","OverlayLocation"],"0800":["CS","1-n","OverlayCodeLabel"],"0802":["US","1","OverlayNumberOfTables"],"0803":["AT","1-n","OverlayCodeTableLocation"],"0804":["US","1","OverlayBitsForCodeWord"],1001:["CS","1","OverlayActivationLayer"],1100:["US","1","OverlayDescriptorGray"],1101:["US","1","OverlayDescriptorRed"],1102:["US","1","OverlayDescriptorGreen"],1103:["US","1","OverlayDescriptorBlue"],1200:["US","1-n","OverlaysGray"],1201:["US","1-n","OverlaysRed"],1202:["US","1-n","OverlaysGreen"],1203:["US","1-n","OverlaysBlue"],1301:["IS","1","ROIArea"],1302:["DS","1","ROIMean"],1303:["DS","1","ROIStandardDeviation"],1500:["LO","1","OverlayLabel"],3e3:["ox","1","OverlayData"],4e3:["LT","1","OverlayComments"]},"7F00":{"0000":["UL","1","GenericGroupLength"],"0010":["ox","1","VariablePixelData"],"0011":["US","1","VariableNextDataGroup"],"0020":["OW","1","VariableCoefficientsSDVN"],"0030":["OW","1","VariableCoefficientsSDHN"],"0040":["OW","1","VariableCoefficientsSDDN"]},"7FE0":{"0000":["UL","1","GenericGroupLength"],"0001":["OV","1","ExtendedOffsetTable"],"0002":["OV","1","ExtendedOffsetTableLengths"],"0008":["OF","1","FloatPixelData"],"0009":["OD","1","DoubleFloatPixelData"],"0010":["ox","1","PixelData"],"0020":["OW","1","CoefficientsSDVN"],"0030":["OW","1","CoefficientsSDHN"],"0040":["OW","1","CoefficientsSDDN"]},FFFA:{"0000":["UL","1","GenericGroupLength"],FFFA:["SQ","1","DigitalSignaturesSequence"]},FFFC:{"0000":["UL","1","GenericGroupLength"],FFFC:["OB","1","DataSetTrailingPadding"]},FFFE:{"0000":["UL","1","GenericGroupLength"],E000:["NONE","1","Item"],E00D:["NONE","1","ItemDelimitationItem"],E0DD:["NONE","1","SequenceDelimitationItem"]}},Ve={"0000":"Command","0002":"Meta Element","0004":"File Set","0008":"Identifying","0009":"SPI Identifying","0010":"Patient","0012":"Clinical Trial","0018":"Acquisition","0019":"SPI Acquisition","0020":"Image","0021":"SPI Image","0022":"Ophtalmology","0028":"Image Presentation","0032":"Study","0038":"Visit","003A":"Waveform","0040":"Procedure","0042":"Encapsulated Document","0050":"Device Informations","0054":"Nuclear Medicine","0060":"Histogram","0070":"Presentation State","0072":"Hanging Protocol","0088":"Storage","0100":"Authorization","0400":"Digital Signature",1e3:"Code Table",1010:"Zonal Map",2e3:"Film Session",2010:"Film Box",2020:"Image Box",2030:"Annotation",2040:"Overlay Box",2050:"Presentation LUT",2100:"Print Job",2110:"Printer",2120:"Queue",2130:"Print Content",2200:"Media Creation",3002:"RT Image",3004:"RT Dose",3006:"RT StructureSet",3008:"RT Treatment","300A":"RT Plan","300C":"RT Relationship","300E":"RT Approval",4e3:"Text",4008:"Results","4FFE":"MAC Parameters",5e3:"Curve",5002:"Curve",5004:"Curve",5006:"Curve",5008:"Curve","500A":"Curve","500C":"Curve","500E":"Curve",5400:"Waveform Data",6e3:"Overlays",6002:"Overlays",6004:"Overlays",6008:"Overlays","600A":"Overlays","600C":"Overlays","600E":"Overlays",FFFC:"Generic","7FE0":"Pixel Data",FFFF:"Unknown"},Ge=["OB","OD","OF","OL","OV","OW","SQ","SV","UC","UN","UR","UT","UV","ox"],ze=["SH","LO","UC","ST","LT","UT","PN"],He={AE:"string",AS:"string",AT:void 0,CS:"string",DA:"string",DS:"string",DT:"string",FL:"Float32",FD:"Float64",IS:"string",LO:"string",LT:"string",OB:"Uint8",OD:"Uint64",OF:"Uint32",OL:"Uint32",OV:"Uint64",OW:"Uint16",PN:"string",SH:"string",SL:"Int32",SQ:void 0,SS:"Int16",ST:"string",SV:"Int64",TM:"string",UC:"string",UI:"string",UL:"Uint32",UN:"Uint8",UR:"string",US:"Uint16",UT:"string",UV:"Uint64"};function je(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Xe(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,_e(e,t,"get"))}function Ye(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,_e(e,t,"set"),n),n}function _e(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Ze=new WeakMap,Ke=new WeakMap;class Je{constructor(e,t){if(je(this,Ze,{writable:!0,value:void 0}),je(this,Ke,{writable:!0,value:void 0}),!e||void 0===e)throw new Error("Cannot create tag with no group.");if(4!==e.length)throw new Error("Cannot create tag with badly sized group.");if(!t||void 0===t)throw new Error("Cannot create tag with no element.");if(4!==t.length)throw new Error("Cannot create tag with badly sized element.");Ye(this,Ze,e),Ye(this,Ke,t)}getGroup(){return Xe(this,Ze)}getElement(){return Xe(this,Ke)}toString(){return this.getKey()+": "+this.getNameFromDictionary()}equals(e){return null!=e&&this.getGroup()===e.getGroup()&&this.getElement()===e.getElement()}getKey(){return this.getGroup()+this.getElement()}getGroupName(){return Ve[this.getGroup()]}isWithVR(){const e=this.getElement();return!("FFFE"===this.getGroup()&&("E000"===e||"E00D"===e||"E0DD"===e))}isPrivate(){return parseInt(this.getGroup(),16)%2==1}getInfoFromDictionary(){let e;return void 0!==We[this.getGroup()]&&void 0!==We[this.getGroup()][this.getElement()]&&(e=We[this.getGroup()][this.getElement()]),e}getVrFromDictionary(){let e;const t=this.getInfoFromDictionary();return void 0!==t&&(e=t[0]),e}getNameFromDictionary(){let e;const t=this.getInfoFromDictionary();return void 0!==t&&(e=t[2]),e}}function $e(e){return new Je(e.substring(0,4),e.substring(4,8))}function et(){return new Je("FFFE","E000")}function tt(e){return e.equals(et())}function nt(){return new Je("FFFE","E00D")}function it(){return new Je("FFFE","E0DD")}function rt(e){return e.equals(it())}function at(){return new Je("7FE0","0010")}function ot(e){return e.equals(at())}function st(e){if(null==e)return null;let t=null,n=null;const i=We,r=Object.keys(i);let a=null,o=!1;for(let s=0,l=r.length;s<l;++s){t=r[s],a=Object.keys(i[t]);for(let r=0,s=a.length;r<s;++r)if(n=a[r],i[t][n][2]===e){o=!0;break}if(o)break}let s=null;return o&&(s=new Je(t,n)),s}function lt(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function ct(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,ht(e,t,"get"))}function ut(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,ht(e,t,"set"),n),n}function ht(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function dt(e){const t=e.byteLength,n=new Uint8Array(e.buffer,e.byteOffset,t),i=e.BYTES_PER_ELEMENT;let r;for(let e=0;e<t;e+=i)for(let t=e+i-1,a=e;t>a;t--,a++)r=n[a],n[a]=n[t],n[t]=r}var St=new WeakMap,gt=new WeakMap,pt=new WeakMap,ft=new WeakMap,mt=new WeakMap;class yt{constructor(e,t){lt(this,St,{writable:!0,value:void 0}),lt(this,gt,{writable:!0,value:!0}),lt(this,pt,{writable:!0,value:new Int8Array(new Int16Array([1]).buffer)[0]>0}),lt(this,ft,{writable:!0,value:void 0}),lt(this,mt,{writable:!0,value:void 0}),ut(this,St,e),void 0!==t&&ut(this,gt,t),ut(this,ft,ct(this,gt)!==ct(this,pt)),ut(this,mt,new DataView(e))}readUint16(e){return ct(this,mt).getUint16(e,ct(this,gt))}readInt16(e){return ct(this,mt).getInt16(e,ct(this,gt))}readUint32(e){return ct(this,mt).getUint32(e,ct(this,gt))}readBigUint64(e){return ct(this,mt).getBigUint64(e,ct(this,gt))}readInt32(e){return ct(this,mt).getInt32(e,ct(this,gt))}readBigInt64(e){return ct(this,mt).getBigInt64(e,ct(this,gt))}readFloat32(e){return ct(this,mt).getFloat32(e,ct(this,gt))}readFloat64(e){return ct(this,mt).getFloat64(e,ct(this,gt))}readBinaryArray(e,t){const n=new Uint8Array(ct(this,St),e,t),i=8*n.length,r=new Uint8Array(i);let a=0,o=0;for(let e=0;e<i;++e)a=e%8,o=Math.floor(e/8),r[e]=255*(0!=(n[o]&1<<a));return r}readUint8Array(e,t){return new Uint8Array(ct(this,St),e,t)}readInt8Array(e,t){return new Int8Array(ct(this,St),e,t)}readUint16Array(e,t){const n=Uint16Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new Uint16Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new Uint16Array(i);for(let t=0;t<i;++t)r[t]=this.readUint16(e+n*t)}return r}readInt16Array(e,t){const n=Int16Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new Int16Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new Int16Array(i);for(let t=0;t<i;++t)r[t]=this.readInt16(e+n*t)}return r}readUint32Array(e,t){const n=Uint32Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new Uint32Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new Uint32Array(i);for(let t=0;t<i;++t)r[t]=this.readUint32(e+n*t)}return r}readUint64Array(e,t){const n=BigUint64Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new BigUint64Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new BigUint64Array(i);for(let t=0;t<i;++t)r[t]=this.readBigUint64(e+n*t)}return r}readInt32Array(e,t){const n=Int32Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new Int32Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new Int32Array(i);for(let t=0;t<i;++t)r[t]=this.readInt32(e+n*t)}return r}readInt64Array(e,t){const n=BigInt64Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new BigInt64Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new BigInt64Array(i);for(let t=0;t<i;++t)r[t]=this.readBigInt64(e+n*t)}return r}readFloat32Array(e,t){const n=Float32Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new Float32Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new Float32Array(i);for(let t=0;t<i;++t)r[t]=this.readFloat32(e+n*t)}return r}readFloat64Array(e,t){const n=Float64Array.BYTES_PER_ELEMENT,i=t/n;let r=null;if(e%n==0)r=new Float64Array(ct(this,St),e,i),ct(this,ft)&&dt(r);else{r=new Float64Array(i);for(let t=0;t<i;++t)r[t]=this.readFloat64(e+n*t)}return r}readHex(e){const t=this.readUint16(e).toString(16);return"0000".substring(0,4-t.length)+t.toUpperCase()}}function vt(e,t,n){if(null==e||null==t)return!1;const i=n>0?0|n:0;return e.substring(i,i+t.length)===t}function Dt(e,t){return null!=e&&null!=t&&e.substring(e.length-t.length)===t}function wt(e){const t=[];if(null==e)return t;const n=/{(\w+)}/g;let i=n.exec(e);for(;i;)t.push(i[1]),i=n.exec(e);return t}function Ct(e,t){let n="";if(null==e)return n;if(n=e,null==t)return n;const i=wt(e);for(let e=0;e<i.length;++e){const r=t[i[e]];if(null!=r&&null!==r.value&&void 0!==r.value){let t=r.value.toPrecision(4);null!==r.unit&&void 0!==r.unit&&0!==r.unit.length&&("degree"!==r.unit&&(t+=" "),t+=r.unit);const a="{"+i[e]+"}";n=n.replace(a,t)}}return n}function Tt(e){let t=null;if(null!=e&&"."!==e[0]){const n=e.toLowerCase().split(".");1!==n.length&&(t=n.pop(),/[a-z]/.test(t)&&!t.includes("/")||(t=null))}return t}function It(e){const t=new Uint8Array(e.length);for(let n=0,i=e.length;n<i;n++)t[n]=e.charCodeAt(n);return t}function Lt(e,t){const n=Math.pow(10,t),i=.01/n;return Math.round(e*n+i)/n}function bt(e,t){return null!==e&&null!==t&&void 0!==e&&void 0!==t&&Pt(e.slice().sort(),t.slice().sort())}function Pt(e,t){return null!==e&&null!==t&&void 0!==e&&void 0!==t&&e.length===t.length&&e.every((function(e,n){return e===t[n]}))}function At(e){return String.fromCharCode.apply(String,e)}function Ot(e,t,n,i){(void 0===n||n<0||n>=e.length)&&(n=0),(void 0===i||i<=n||i>e.length)&&(i=e.length);for(let r=n;r<i;++r)if(t(e[r],r,e))return r}function xt(e){return function(t,n,i){for(let t=0;t<e.length;++t)if(i[n+t]!==e[t])return!1;return!0}}function Ft(e,t){const n="\r\n";let i=0;const r=[];for(let a=0;a<e.length;++a){let o="";0!==a&&(o+=n),o+="--"+t+n;const s=Object.keys(e[a]);for(let t=0;t<s.length;++t){const i=s[t];"data"!==i&&(o+=i+": "+e[a][i]+n)}o+=n;const l=It(o);r.push(l),i+=l.byteLength+e[a].data.byteLength}const a=It("\r\n--"+t+"--"+n),o=new Uint8Array(i+a.byteLength);let s=0;for(let t=0;t<e.length;++t)o.set(r[t],s),s+=r[t].byteLength,o.set(new Uint8Array(e[t].data),s),s+=e[t].data.byteLength;return o.set(a,s),o}function Rt(e,t){Mt(e,t),t.add(e)}function Et(e,t,n){Mt(e,t),t.set(e,n)}function Mt(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function qt(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Ut(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,kt(e,t,"set"),n),n}function Qt(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,kt(e,t,"get"))}function kt(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function Bt(){return"0.32.0-beta.0"}class Nt{decode(e){let t="";for(let n=0,i=e.length;n<i;++n)t+=String.fromCharCode(e[n]);return t}}function Wt(e){let t;return Pt(e,[1,0,0,0,1,0])?t="axial":Pt(e,[1,0,0,0,0,-1])?t="coronal":Pt(e,[0,1,0,0,0,-1])&&(t="sagittal"),t}function Vt(e){return"1.2.840.10008.1.2"===e}function Gt(e){return"1.2.840.10008.1.2.2"===e}function zt(e){return"1.2.840.10008.1.2.4.50"===e||"1.2.840.10008.1.2.4.51"===e}function Ht(e){return"1.2.840.10008.1.2.4.57"===e||"1.2.840.10008.1.2.4.70"===e}function jt(e){return null!==e.match(/1.2.840.10008.1.2.4.9/)}function Xt(e){return null!==e.match(/1.2.840.10008.1.2.5/)}function Yt(e,t,n){let i=null;try{8===e?i=0===t?new Uint8Array(n):new Int8Array(n):16===e?i=0===t?new Uint16Array(n):new Int16Array(n):32===e&&(i=0===t?new Uint32Array(n):new Int32Array(n))}catch(e){if(e instanceof RangeError){const e=Math.floor(Math.log(n)/Math.log(2));re.error("Cannot allocate array of size: "+n+" (>2^"+e+").")}}return i}function _t(e){return Ge.includes(e)}function Zt(e,t){return t?8:_t(e)?12:8}var Kt=new WeakMap,Jt=new WeakMap,$t=new WeakMap,en=new WeakMap,tn=new WeakSet,nn=new WeakSet,rn=new WeakSet,an=new WeakSet,on=new WeakSet,sn=new WeakSet,ln=new WeakSet,cn=new WeakSet;class un{constructor(){Rt(this,cn),Rt(this,ln),Rt(this,sn),Rt(this,on),Rt(this,an),Rt(this,rn),Rt(this,nn),Rt(this,tn),Et(this,Kt,{writable:!0,value:{}}),Et(this,Jt,{writable:!0,value:void 0}),Et(this,$t,{writable:!0,value:new Nt}),Et(this,en,{writable:!0,value:Qt(this,$t)})}getDefaultCharacterSet(){return Qt(this,Jt)}setDefaultCharacterSet(e){Ut(this,Jt,e)}setDecoderCharacterSet(e){Ut(this,en,new TextDecoder(e))}getDicomElements(){return Qt(this,Kt)}parse(e){let t=0,n="",i=null;const r=new yt(e);let a=new yt(e);t=128;const o=qt(this,tn,hn).call(this,r.readUint8Array(t,4));if(t+=4*Uint8Array.BYTES_PER_ELEMENT,"DICM"===o){i=qt(this,sn,fn).call(this,r,t,!1),i.value=qt(this,ln,mn).call(this,i,r),t=i.endOffset,Qt(this,Kt)[i.tag.getKey()]=i;const e=t+i.value[0];for(;t<e;)i=qt(this,sn,fn).call(this,r,t,!1),t=i.endOffset,Qt(this,Kt)[i.tag.getKey()]=i;if(i=Qt(this,Kt)["00020010"],void 0===i)throw new Error("Not a valid DICOM file (no TransferSyntaxUID found)");i.value=qt(this,ln,mn).call(this,i,r),n=i.value[0]}else{re.warn("No DICM prefix, trying to guess tansfer syntax."),i=qt(this,sn,fn).call(this,a,0,!1);const e=function(e){const t="0008",n=e.tag.getGroup();if("0800"!==n&&n!==t)throw new Error("Not a valid DICOM file (no magic DICM word found and first element not in 0008 group)");const i=e.vr,r=i.charCodeAt(0),a=i.charCodeAt(1),o=!(r>=65&&r<=90&&a>=65&&a<=90);let s=null;if(n===t)s=o?"1.2.840.10008.1.2":"1.2.840.10008.1.2.1";else{if(o)throw new Error("Not a valid DICOM file (no magic DICM word foundand implicit VR big endian detected)");s="1.2.840.10008.1.2.2"}const l={tag:new Je("0002","0010"),vr:"UI"};return l.value=[s+" "],l.vl=l.value[0].length,l.startOffset=e.startOffset,l.endOffset=l.startOffset+l.vl,l}(i);Qt(this,Kt)[e.tag.getKey()]=e,n=e.value[0],t=0}if(!function(e){return"1.2.840.10008.1.2"===e||"1.2.840.10008.1.2.1"===e||"1.2.840.10008.1.2.2"===e||zt(e)||Ht(e)||jt(e)||Xt(e)}(n))throw new Error("Unsupported DICOM transfer syntax: '"+n+"' ("+function(e){let t="Unknown";return"1.2.840.10008.1.2"===e?t="Little Endian Implicit":"1.2.840.10008.1.2.1"===e?t="Little Endian Explicit":"1.2.840.10008.1.2.1.99"===e?t="Little Endian Deflated Explicit":"1.2.840.10008.1.2.2"===e?t="Big Endian Explicit":zt(e)?t="1.2.840.10008.1.2.4.50"===e?"JPEG Baseline":"JPEG Extended, Process 2+4":Ht(e)?t="1.2.840.10008.1.2.4.57"===e?"JPEG Lossless, Nonhierarchical (Processes 14)":"JPEG Lossless, Non-hierarchical, 1st Order Prediction":function(e){return null!==e.match(/1.2.840.10008.1.2.4.5/)&&!zt(e)&&!Ht(e)||null!==e.match(/1.2.840.10008.1.2.4.6/)}(e)?t="Retired JPEG":function(e){return null!==e.match(/1.2.840.10008.1.2.4.8/)}(e)?t="JPEG-LS":jt(e)?t="1.2.840.10008.1.2.4.91"===e?"JPEG 2000 (Lossless or Lossy)":"JPEG 2000 (Lossless only)":"1.2.840.10008.1.2.4.100"===e?t="MPEG2":Xt(e)&&(t="RLE"),t}(n)+")");let s=!1;for(Vt(n)&&(s=!0),Gt(n)&&(a=new yt(e,!1));t<e.byteLength;)i=qt(this,sn,fn).call(this,a,t,s),t=i.endOffset,void 0===Qt(this,Kt)[i.tag.getKey()]?Qt(this,Kt)[i.tag.getKey()]=i:re.warn("Not saving duplicate tag: "+i.tag.getKey());if(isNaN(t))throw new Error("Problem while parsing, bad offset");e.byteLength!==t&&re.warn("Did not reach the end of the buffer: "+t+" != "+e.byteLength);let l=0,c=16;if(void 0!==Qt(this,Kt)["7FE00010"]&&(i=Qt(this,Kt)["00280103"],void 0!==i?(i.value=qt(this,ln,mn).call(this,i,a),l=i.value[0]):re.warn("Reading DICOM pixel data with default pixelRepresentation."),i=Qt(this,Kt)["00280100"],void 0!==i?(i.value=qt(this,ln,mn).call(this,i,a),c=i.value[0]):re.warn("Reading DICOM pixel data with default bitsAllocated.")),void 0!==this.getDefaultCharacterSet()&&this.setDecoderCharacterSet(this.getDefaultCharacterSet()),i=Qt(this,Kt)["00080005"],void 0!==i){let e;i.value=qt(this,ln,mn).call(this,i,a),1===i.value.length?e=i.value[0]:(e=i.value[1],re.warn("Unsupported character set with code extensions: '"+e+"'.")),this.setDecoderCharacterSet(function(e){let t="utf-8";return"ISO_IR 100"===e?t="iso-8859-1":"ISO_IR 101"===e?t="iso-8859-2":"ISO_IR 109"===e?t="iso-8859-3":"ISO_IR 110"===e?t="iso-8859-4":"ISO_IR 144"===e?t="iso-8859-5":"ISO_IR 127"===e?t="iso-8859-6":"ISO_IR 126"===e?t="iso-8859-7":"ISO_IR 138"===e?t="iso-8859-8":"ISO_IR 148"===e?t="iso-8859-9":"ISO_IR 13"===e?t="shift-jis":"ISO_IR 166"===e?t="iso-8859-11":"ISO 2022 IR 87"===e?t="iso-2022-jp":"ISO 2022 IR 149"===e||"ISO 2022 IR 58"===e||("ISO_IR 192"===e?t="utf-8":"GB18030"===e?t="gb18030":"GB2312"===e?t="gb2312":"GBK"===e&&(t="chinese")),t}(e))}if(qt(this,cn,yn).call(this,Qt(this,Kt),a,l,c),i=Qt(this,Kt)["7FE00010"],void 0!==i&&i.undefinedLength){let e=1;void 0!==Qt(this,Kt)["00280008"]&&(e=Number(Qt(this,Kt)["00280008"].value[0]));const t=i.value;if(t.length>1&&t.length>e){const n=t.length/e,r=[];let a=0;for(let i=0;i<e;++i){a=i*n;let e=0;for(let i=0;i<n;++i)e+=t[a+i].length;const o=new t[0].constructor(e);let s=0;for(let e=0;e<n;++e)o.set(t[a+e],s),s+=t[a+e].length;r[i]=o}i.value=r}}}}function hn(e){return Qt(this,$t).decode(e)}function dn(e){return Qt(this,en).decode(e)}function Sn(e,t){const n=e.readHex(t);t+=Uint16Array.BYTES_PER_ELEMENT;const i=e.readHex(t);return t+=Uint16Array.BYTES_PER_ELEMENT,{tag:new Je(n,i),endOffset:t}}function gn(e,t,n){const i={};let r=qt(this,sn,fn).call(this,e,t,n);if(t=r.endOffset,rt(r.tag))return{data:i,endOffset:r.endOffset,isSeqDelim:!0};if(i[r.tag.getKey()]={tag:r.tag,vr:"NONE",vl:r.vl,undefinedLength:r.undefinedLength},r.undefinedLength){let a=!1;for(;!a;)r=qt(this,sn,fn).call(this,e,t,n),t=r.endOffset,a=r.tag.equals(nt()),a||(i[r.tag.getKey()]=r)}else{const a=t;for(t-=r.vl;t<a;)r=qt(this,sn,fn).call(this,e,t,n),t=r.endOffset,i[r.tag.getKey()]=r}return{data:i,endOffset:t,isSeqDelim:!1}}function pn(e,t,n){const i=[];let r=qt(this,sn,fn).call(this,e,t,n);const a=r.vl;t=r.endOffset;let o=!1;for(;!o;)r=qt(this,sn,fn).call(this,e,t,n),t=r.endOffset,o=rt(r.tag),o||(r.vr="OB",i.push(r));return{data:i,endOffset:t,offsetTableVl:a}}function fn(e,t,n){const i=qt(this,rn,Sn).call(this,e,t),r=i.tag;t=i.endOffset;let a=null,o=!1;r.isWithVR()?n?(a=r.getVrFromDictionary(),void 0===a&&(a="UN"),o=!0):(a=qt(this,tn,hn).call(this,e.readUint8Array(t,2)),t+=2*Uint8Array.BYTES_PER_ELEMENT,o=_t(a),o&&(t+=2*Uint8Array.BYTES_PER_ELEMENT)):(a="NONE",o=!0);let s=0;o?(s=e.readUint32(t),t+=Uint32Array.BYTES_PER_ELEMENT):(s=e.readUint16(t),t+=Uint16Array.BYTES_PER_ELEMENT);let l=!1;4294967295===s&&(l=!0,s=0),r.isPrivate()&&"UN"===a&&0===s&&(a="SQ");let c=t,u=c+s,h=null;if(ot(r)&&l){const i=qt(this,on,pn).call(this,e,t,n);t=i.endOffset,c+=i.offsetTableVl,h=i.data,u=t,s=t-c}else if("SQ"===a){let i;if(h=[],l){let r=!1;for(;!r;)i=qt(this,an,gn).call(this,e,t,n),r=i.isSeqDelim,t=i.endOffset,r||h.push(i.data);u=t,s=t-c}else if(0!==s){const r=t+s;for(;t<r;)i=qt(this,an,gn).call(this,e,t,n),h.push(i.data),t=i.endOffset;u=t,s=t-c}}const d={tag:r,vr:a,vl:s,startOffset:c,endOffset:u};return l&&(d.undefinedLength=l),h&&(d.items=h),d}function mn(e,t,n,i){const r=e.tag,a=e.vl,o=e.vr,s=e.startOffset;let l=null;const c=He[o];if(ot(r))if(e.undefinedLength){l=[];for(let r=0;r<e.items.length;++r)l.push(qt(this,ln,mn).call(this,e.items[r],t,n,i));delete e.items}else if(i>8&&"OB"===o&&re.warn("Reading DICOM pixel data with bitsAllocated>8 and OB VR."),l=[],1===i)l.push(t.readBinaryArray(s,a));else if(8===i)0===n?l.push(t.readUint8Array(s,a)):l.push(t.readInt8Array(s,a));else{if(16!==i)throw new Error("Unsupported bits allocated: "+i);0===n?l.push(t.readUint16Array(s,a)):l.push(t.readInt16Array(s,a))}else if(void 0!==c)if("Uint8"===c)l=t.readUint8Array(s,a);else if("Uint16"===c)l=t.readUint16Array(s,a),"O"!==o[0]&&(l=Array.from(l));else if("Uint32"===c)l=t.readUint32Array(s,a),"O"!==o[0]&&(l=Array.from(l));else if("Uint64"===c)l=t.readUint64Array(s,a);else if("Int16"===c)l=Array.from(t.readInt16Array(s,a));else if("Int32"===c)l=Array.from(t.readInt32Array(s,a));else if("Int64"===c)l=t.readInt64Array(s,a);else if("Float32"===c)l=Array.from(t.readFloat32Array(s,a));else if("Float64"===c)l=Array.from(t.readFloat64Array(s,a));else{if("string"!==c)throw Error("Unknown VR type: "+c);{const e=t.readUint8Array(s,a);l=ze.includes(o)?qt(this,nn,dn).call(this,e):qt(this,tn,hn).call(this,e),l=function(e){let t=e;return e&&(t=e.trim(),t[t.length-1]===String.fromCharCode("u200B")&&(t=t.substring(0,t.length-1))),t}(l).split("\\")}}else if("xx"===o)l=Array.from(t.readUint16Array(s,a));else if("ox"===o)l=8===i?Array.from(t.readUint8Array(s,a)):Array.from(t.readUint16Array(s,a));else if("xs"===o)l=0===n?Array.from(t.readUint16Array(s,a)):Array.from(t.readInt16Array(s,a));else if("AT"===o){const e=t.readUint16Array(s,a);l=[];for(let t=0,n=e.length;t<n;t+=2){const n=e[t].toString(16),i=e[t+1].toString(16);let r="(";r+="0000".substring(0,4-n.length)+n.toUpperCase(),r+=",",r+="0000".substring(0,4-i.length)+i.toUpperCase(),r+=")",l.push(r)}}else if("SQ"===o){l=[];for(let r=0;r<e.items.length;++r){const a=e.items[r],o={},s=Object.keys(a);for(let e=0;e<s.length;++e){const r=a[s[e]];r.value=qt(this,ln,mn).call(this,r,t,n,i),delete r.tag,delete r.vl,delete r.startOffset,delete r.endOffset,o[s[e]]=r}l.push(o)}delete e.items}else"NONE"===o||re.warn("Unknown VR: "+o+" (for tag "+e.tag.getKey()+")"),l=[];return l}function yn(e,t,n,i){const r=Object.keys(e);for(let a=0;a<r.length;++a){const o=e[r[a]];void 0===o.value&&(o.value=qt(this,ln,mn).call(this,o,t,n,i)),delete o.tag,delete o.vl,delete o.startOffset,delete o.endOffset}}function vn(e,t){var n=function(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return t.get(e)}(e,t);return function(e,t){return t.get?t.get.call(e):t.value}(e,n)}var Dn=new WeakMap;class wn{constructor(){var e,t,n;n={writable:!0,value:{}},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e=this,t=Dn),t.set(e,n),function(e,t,n){(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n}(this,"fireEvent",(e=>{if(void 0===vn(this,Dn)[e.type])return;const t=vn(this,Dn)[e.type].slice();for(let n=0;n<t.length;++n)t[n](e)}))}add(e,t){void 0===vn(this,Dn)[e]&&(vn(this,Dn)[e]=[]),vn(this,Dn)[e].push(t)}remove(e,t){if(void 0!==vn(this,Dn)[e])for(let n=0;n<vn(this,Dn)[e].length;++n)vn(this,Dn)[e][n]===t&&vn(this,Dn)[e].splice(n,1)}}function Cn(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Tn(e,t,"get"))}function Tn(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var In=new WeakMap;class Ln{constructor(e){if(i={writable:!0,value:void 0},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(t=this,n=In),n.set(t,i),!e||void 0===e)throw new Error("Cannot create size with no values.");var t,n,i;if(0===e.length)throw new Error("Cannot create size with empty values.");if(!e.every((function(e){return!isNaN(e)&&0!==e})))throw new Error("Cannot create size with non number or zero values.");!function(e,t,n){(function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}})(e,Tn(e,t,"set"),n)}(this,In,e)}get(e){return Cn(this,In)[e]}length(){return Cn(this,In).length}toString(){return"("+Cn(this,In).toString()+")"}getValues(){return Cn(this,In).slice()}moreThanOne(e){return this.length()>=e+1&&1!==this.get(e)}canScroll3D(e){let t=2;return void 0!==e&&(t=e.getThirdColMajorDirection()),this.moreThanOne(t)}canScroll(e){let t=this.canScroll3D(e);for(let e=3;e<this.length();++e)t=t||this.moreThanOne(e);return t}getDimSize(e,t){if(e>this.length())return null;if(void 0===t)t=0;else if(t<0||t>e)throw new Error("Invalid start value for getDimSize");let n=1;for(let i=t;i<e;++i)n*=this.get(i);return n}getTotalSize(e){return this.getDimSize(this.length(),e)}equals(e){if(!e)return!1;const t=this.length();if(t!==e.length())return!1;for(let n=0;n<t;++n)if(this.get(n)!==e.get(n))return!1;return!0}isInBounds(e,t){if(!e)return!1;const n=this.length();if(n!==e.length())return!1;if(void 0===t){t=[];for(let e=0;e<n;++e)t.push(e)}else for(let e=0;e<n;++e)if(t[e]>n-1)throw new Error("Wrong input dir value: "+t[e]);for(let n=0;n<t.length;++n)if(i=e.get(t[n]),r=this.get(t[n]),!(i>=0&&i<r))return!1;var i,r;return!0}indexToOffset(e,t){if(e.length()<this.length())throw new Error("Incompatible index and size length");if(void 0===t)t=0;else if(t<0||t>this.length()-1)throw new Error("Invalid start value for indexToOffset");let n=0;for(let i=t;i<this.length();++i)n+=e.get(i)*this.getDimSize(i,t);return n}offsetToIndex(e){const t=new Array(this.length());let n=e,r=0;for(let e=this.length()-1;e>0;--e)r=this.getDimSize(e),t[e]=Math.floor(n/r),n-=t[e]*r;return t[0]=n,new i(t)}get2D(){return{x:this.get(0),y:this.get(1)}}}function bn(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Pn(e,t,"get"))}function Pn(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var An=new WeakMap;class On{constructor(e){if(i={writable:!0,value:void 0},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(t=this,n=An),n.set(t,i),!e||void 0===e)throw new Error("Cannot create spacing with no values.");var t,n,i;if(0===e.length)throw new Error("Cannot create spacing with empty values.");if(!e.every((function(e){return!isNaN(e)&&0!==e})))throw new Error("Cannot create spacing with non number or zero values.");!function(e,t,n){(function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}})(e,Pn(e,t,"set"),n)}(this,An,e)}get(e){return bn(this,An)[e]}length(){return bn(this,An).length}toString(){return"("+bn(this,An).toString()+")"}getValues(){return bn(this,An).slice()}equals(e){if(!e)return!1;const t=this.length();if(t!==e.length())return!1;for(let n=0;n<t;++n)if(this.get(n)!==e.get(n))return!1;return!0}get2D(){return{x:this.get(0),y:this.get(1)}}}function xn(e,t,n){Fn(e,t),t.set(e,n)}function Fn(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Rn(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Mn(e,t,"get"))}function En(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Mn(e,t,"set"),n),n}function Mn(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var qn=new WeakMap,Un=new WeakMap,Qn=new WeakMap,kn=new WeakMap,Bn=new WeakMap,Nn=new WeakMap,Wn=new WeakMap,Vn=new WeakSet;class Gn{constructor(e,t,n,i,r){var a;Fn(this,a=Vn),a.add(this),xn(this,qn,{writable:!0,value:void 0}),xn(this,Un,{writable:!0,value:void 0}),xn(this,Qn,{writable:!0,value:void 0}),xn(this,kn,{writable:!0,value:{}}),xn(this,Bn,{writable:!0,value:void 0}),xn(this,Nn,{writable:!0,value:Le()}),xn(this,Wn,{writable:!0,value:!1}),En(this,qn,[e]),En(this,Un,t),En(this,Qn,n),void 0!==r&&(En(this,Bn,r),Rn(this,kn)[r]=[e]),void 0!==i&&En(this,Nn,i)}getInitialTime(){return Rn(this,Bn)}getCurrentTotalNumberOfSlices(){const e=Object.keys(Rn(this,kn));if(0===e.length)return Rn(this,qn).length;let t=0;for(let n=0;n<e.length;++n)t+=Rn(this,kn)[e[n]].length;return t}hasSlicesAtTime(e){return void 0!==Rn(this,kn)[e]}getCurrentNumberOfSlicesBeforeTime(e){const t=Object.keys(Rn(this,kn));if(0===t.length)return;let n=0;for(let i=0;i<t.length;++i){const r=t[i];if(parseInt(r,10)===e)break;n+=Rn(this,kn)[r].length}return n}getOrigin(){return Rn(this,qn)[0]}getOrigins(){return Rn(this,qn)}includesOrigin(e,t){for(let n=0;n<Rn(this,qn).length;++n)if(Rn(this,qn)[n].isSimilar(e,t))return!0;return!1}getSize(e){let t=Rn(this,Un);if(e&&void 0!==e){let n=Hn([Rn(this,Un).get(0),Rn(this,Un).get(1),Rn(this,Un).get(2)],e);n=n.map(Math.abs),t=new Ln(n.concat(Rn(this,Un).getValues().slice(3)))}return t}getSpacing(e){Rn(this,Wn)&&(function(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}(this,Vn,zn).call(this),En(this,Wn,!1));let t=Rn(this,Qn);if(e&&void 0!==e){let n=Hn([Rn(this,Qn).get(0),Rn(this,Qn).get(1),Rn(this,Qn).get(2)],e);n=n.map(Math.abs),t=new On(n)}return t}getRealSpacing(){return this.getSpacing(Rn(this,Nn).getInverse().asOneAndZeros())}getOrientation(){return Rn(this,Nn)}getSliceIndex(e,t){let n=Rn(this,qn);void 0!==t&&(n=Rn(this,kn)[t]);let i=0,r=e.getDistance(n[0]),a=0;for(let t=0;t<n.length;++t)a=e.getDistance(n[t]),a<r&&(r=a,i=t);const o=n[i],s=e.minus(o);return new pe(Rn(this,Nn).get(0,2),Rn(this,Nn).get(1,2),Rn(this,Nn).get(2,2)).dotProduct(s)>0?i+1:i}appendOrigin(e,t,n){if(void 0!==n&&Rn(this,kn)[n].splice(t,0,e),void 0===n||n===Rn(this,Bn)){En(this,Wn,!0),Rn(this,qn).splice(t,0,e);const n=Rn(this,Un).getValues();n[2]+=1,En(this,Un,new Ln(n))}}appendFrame(e,t){Rn(this,kn)[t]=[e];const n=Rn(this,Un).getValues(),i=Rn(this,Qn).getValues();4===n.length?n[3]+=1:(n.push(2),i.push(1)),En(this,Un,new Ln(n)),En(this,Qn,new On(i))}toString(){return"Origin: "+this.getOrigin()+", Size: "+this.getSize()+", Spacing: "+this.getSpacing()+", Orientation: "+this.getOrientation()}equals(e){return null!==e&&this.getOrigin().equals(e.getOrigin())&&this.getSize().equals(e.getSize())&&this.getSpacing().equals(e.getSpacing())}isInBounds(e){return this.isIndexInBounds(this.worldToIndex(e))}isIndexInBounds(e,t){return this.getSize().isInBounds(e,t)}indexToWorld(e){const t=this.getSpacing(),n=new ke(e.get(0)*t.get(0),e.get(1)*t.get(1),e.get(2)*t.get(2)),i=this.getOrientation().multiplyPoint3D(n),r=e.getValues(),a=this.getOrigin();return r[0]=a.getX()+i.getX(),r[1]=a.getY()+i.getY(),r[2]=a.getZ()+i.getZ(),new Ne(r)}pointToWorld(e){const t=this.getSpacing(),n=new ke(e.getX()*t.get(0),e.getY()*t.get(1),e.getZ()*t.get(2)),i=this.getOrientation().multiplyPoint3D(n),r=this.getOrigin();return new ke(r.getX()+i.getX(),r.getY()+i.getY(),r.getZ()+i.getZ())}worldToIndex(e){const t=this.getOrigin(),n=new ke(e.get(0)-t.getX(),e.get(1)-t.getY(),e.get(2)-t.getZ()),r=this.getOrientation().getInverse().multiplyPoint3D(n),a=e.getValues(),o=this.getSpacing();return a[0]=Math.round(r.getX()/o.get(0)),a[1]=Math.round(r.getY()/o.get(1)),a[2]=Math.round(r.getZ()/o.get(2)),new i(a)}worldToPoint(e){const t=this.getOrigin(),n=new ke(e.get(0)-t.getX(),e.get(1)-t.getY(),e.get(2)-t.getZ()),i=this.getOrientation().getInverse().multiplyPoint3D(n),r=e.getValues(),a=this.getSpacing();return r[0]=i.getX()/a.get(0),r[1]=i.getY()/a.get(1),r[2]=i.getZ()/a.get(2),new ke(r[0],r[1],r[2])}}function zn(){const e=Xn(Rn(this,qn),Rn(this,Nn));if(void 0!==e&&Rn(this,Qn).get(2)!==e){re.trace("Updating slice spacing.");const t=Rn(this,Qn).getValues();t[2]=e,En(this,Qn,new On(t))}}function Hn(e,t){return t.getInverse().multiplyArray3D(e)}function jn(e,t){return t.multiplyArray3D(e)}function Xn(e,t,n){if(void 0===n&&(n=!0),e.length<=1)return;const i=t.getInverse();let r=i.multiplyVector3D(e[0]),a=i.multiplyVector3D(e[1]),o=Math.abs(r.getZ()-a.getZ());const s=[];for(let t=0;t<e.length-1;++t){r=i.multiplyVector3D(e[t]),a=i.multiplyVector3D(e[t+1]);const l=Math.abs(r.getZ()-a.getZ());if(0===l)throw new Error("Zero slice spacing."+r.toString()+" "+a.toString());l<o&&(o=l),n&&(we(o,l,De)||s.push(Math.abs(o-l)))}if(n&&0!==s.length){const e=function(e,t){return e+t},t=s.reduce(e)/s.length;t>1e-4&&re.warn("Varying slice spacing, mean delta: "+t.toFixed(3)+" ("+s.length+" case(s))")}return o}function Yn(e,t){Zn(e,t),t.add(e)}function _n(e,t,n){Zn(e,t),t.set(e,n)}function Zn(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Kn(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Jn(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,ei(e,t,"get"))}function $n(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,ei(e,t,"set"),n),n}function ei(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var ti=new WeakMap,ni=new WeakMap,ii=new WeakMap,ri=new WeakMap,ai=new WeakMap,oi=new WeakMap,si=new WeakMap,li=new WeakMap,ci=new WeakMap,ui=new WeakMap,hi=new WeakMap,di=new WeakMap,Si=new WeakMap,gi=new WeakMap,pi=new WeakMap,fi=new WeakSet,mi=new WeakSet,yi=new WeakSet,vi=new WeakMap;class Di{constructor(e,t,n){Yn(this,yi),Yn(this,mi),Yn(this,fi),_n(this,ti,{writable:!0,value:void 0}),_n(this,ni,{writable:!0,value:void 0}),_n(this,ii,{writable:!0,value:void 0}),_n(this,ri,{writable:!0,value:new S(1,0)}),_n(this,ai,{writable:!0,value:null}),_n(this,oi,{writable:!0,value:!0}),_n(this,si,{writable:!0,value:!0}),_n(this,li,{writable:!0,value:"MONOCHROME2"}),_n(this,ci,{writable:!0,value:0}),_n(this,ui,{writable:!0,value:void 0}),_n(this,hi,{writable:!0,value:{}}),_n(this,di,{writable:!0,value:null}),_n(this,Si,{writable:!0,value:null}),_n(this,gi,{writable:!0,value:null}),_n(this,pi,{writable:!0,value:new wn}),_n(this,vi,{writable:!0,value:e=>{Jn(this,pi).fireEvent(e)}}),$n(this,ti,e),$n(this,ni,t),$n(this,ii,n),$n(this,ui,Jn(this,ni).length/Jn(this,ti).getSize().getTotalSize())}getImageUid(e){let t=Jn(this,ii)[0];return 1!==Jn(this,ii).length&&void 0!==e&&(t=Jn(this,ii)[this.getSecondaryOffset(e)]),t}getGeometry(){return Jn(this,ti)}getBuffer(){return Jn(this,ni)}canQuantify(){return 1===this.getNumberOfComponents()}canWindowLevel(){return null!==this.getPhotometricInterpretation().match(/MONOCHROME/)}canScroll(e){const t=this.getGeometry().getSize();let n=1;return void 0!==Jn(this,hi).numberOfFiles&&(n=Jn(this,hi).numberOfFiles),t.canScroll(e)||1!==n}getSecondaryOffset(e){return Jn(this,ti).getSize().indexToOffset(e,2)}getRescaleSlopeAndIntercept(e){let t=Jn(this,ri);if(!this.isConstantRSI()){if(void 0===e)throw new Error("Cannot get non constant RSI with empty slice index.");const n=this.getSecondaryOffset(e);void 0!==Jn(this,ai)[n]?t=Jn(this,ai)[n]:re.warn("undefined non constant rsi at "+n)}return t}setRescaleSlopeAndIntercept(e,t){if($n(this,oi,Jn(this,oi)&&e.isID()),Jn(this,si)){if(!Jn(this,ri).equals(e))if(void 0===t)$n(this,ri,e);else{$n(this,si,!1),$n(this,ai,[]);for(let e=0,t=Kn(this,fi,wi).call(this);e<t;++e)Jn(this,ai).push(e);$n(this,ri,null),Jn(this,ai).splice(t,0,e)}}else{if(void 0===t)throw new Error("Cannot store non constant RSI with empty slice index.");Jn(this,ai).splice(t,0,e)}}isIdentityRSI(){return Jn(this,oi)}isConstantRSI(){return Jn(this,si)}getPhotometricInterpretation(){return Jn(this,li)}setPhotometricInterpretation(e){$n(this,li,e)}getPlanarConfiguration(){return Jn(this,ci)}setPlanarConfiguration(e){$n(this,ci,e)}getNumberOfComponents(){return Jn(this,ui)}getMeta(){return Jn(this,hi)}setMeta(e){$n(this,hi,e)}getValueAtOffset(e){return Jn(this,ni)[e]}getOffsets(e){1===Jn(this,ui)?e=[e]:3===Jn(this,ui)&&void 0!==e.r&&(e=[e.r,e.g,e.b]);const t=[];let n;for(let i=0;i<Jn(this,ni).length;i+=Jn(this,ui)){n=!0;for(let t=0;t<Jn(this,ui);++t)if(Jn(this,ni)[i+t]!==e[t]){n=!1;break}n&&t.push(i)}return t}hasValues(e){if(void 0===e||0===e.length)return[];const t=[];for(let n=0;n<e.length;++n)1===Jn(this,ui)?t.push([e[n]]):3===Jn(this,ui)&&t.push([e[n].r,e[n].g,e[n].b]);let n;1===Jn(this,ui)?n=function(e,t){return e[0]===t[0]}:3===Jn(this,ui)&&(n=function(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]});const i=function(e){return function(t){return n(t,e)}},r=new Array(e.length);r.fill(!1);const a=t.slice();let o,s;for(let e=0,n=Jn(this,ni).length;e<n;e+=Jn(this,ui)){s=[];for(let n=0;n<a.length;++n){o=!0;for(let t=0;t<Jn(this,ui);++t)if(Jn(this,ni)[e+t]!==a[n][t]){o=!1;break}o&&(r[t.findIndex(i(a[n]))]=!0,s.push(n))}for(let e=0;e<s.length;++e)a.splice(s[e],1);if(0===a.length)break}return r}clone(){const e=Jn(this,ni).slice(0),t=new Di(this.getGeometry(),e,Jn(this,ii));if(this.isConstantRSI())t.setRescaleSlopeAndIntercept(this.getRescaleSlopeAndIntercept());else for(let e=0;e<Kn(this,fi,wi).call(this);++e)t.setRescaleSlopeAndIntercept(Kn(this,mi,Ci).call(this,e),e);return t.setPhotometricInterpretation(this.getPhotometricInterpretation()),t.setPlanarConfiguration(this.getPlanarConfiguration()),t.setMeta(this.getMeta()),t}appendSlice(e){if(null===e)throw new Error("Cannot append null slice");const t=e.getGeometry().getSize();let n=Jn(this,ti).getSize();if(1!==t.get(2))throw new Error("Cannot append more than one slice");if(n.get(0)!==t.get(0))throw new Error("Cannot append a slice with different number of columns");if(n.get(1)!==t.get(1))throw new Error("Cannot append a slice with different number of rows");if(!Jn(this,ti).getOrientation().equals(e.getGeometry().getOrientation(),1e-4))throw new Error("Cannot append a slice with different orientation");if(Jn(this,li)!==e.getPhotometricInterpretation())throw new Error("Cannot append a slice with different photometric interpretation");for(const t in Jn(this,hi))if("windowPresets"!==t&&"numberOfFiles"!==t&&"custom"!==t&&Jn(this,hi)[t]!==e.getMeta()[t])throw new Error("Cannot append a slice with different "+t);const r=e.getGeometry().getInitialTime();let a=!1;void 0===r||Jn(this,ti).hasSlicesAtTime(r)||(this.appendFrame(r,e.getGeometry().getOrigin()),n=Jn(this,ti).getSize(),a=!0);const o=function(e,t){const n=t.getInitialTime(),r=[];return r.push(0),r.push(0),r.push(e.getSliceIndex(t.getOrigin(),n)),void 0!==n&&r.push(n),new i(r)}(Jn(this,ti),e.getGeometry()),s=Jn(this,ui)*n.getDimSize(2);if(void 0===Jn(this,hi).numberOfFiles)throw new Error("Missing number of files for buffer manipulation.");const l=s*Jn(this,hi).numberOfFiles;Jn(this,ni).length!==l&&Kn(this,yi,Ti).call(this,l);const c=o.get(2);let u=c;void 0!==r&&(u+=Jn(this,ti).getCurrentNumberOfSlicesBeforeTime(r));const h=u*s,d=Jn(this,ti).getCurrentTotalNumberOfSlices()*s;h<d&&Jn(this,ni).set(Jn(this,ni).subarray(h,d),h+s),Jn(this,ni).set(e.getBuffer(),h),a||Jn(this,ti).appendOrigin(e.getGeometry().getOrigin(),c,r),this.setRescaleSlopeAndIntercept(e.getRescaleSlopeAndIntercept(),u);const S=Jn(this,ii).length;if(Jn(this,ii).splice(u,0,e.getImageUid()),void 0!==Jn(this,hi).windowPresets){const t=Jn(this,hi).windowPresets,n=e.getMeta().windowPresets,i=Object.keys(n);let r=null;for(let e=0;e<i.length;++e){r=i[e];const a=n[r],o=t[r];if(void 0!==o){if((void 0===o.perslice||!1===o.perslice)&&!o.wl[0].equals(a.wl[0])){o.perslice=!0;for(let e=0;e<S-1;++e)o.wl.push(o.wl[0])}void 0!==o.perslice&&!0===o.perslice&&t[r].wl.splice(u,0,a.wl[0])}else t[r]=n[r]}}}appendFrameBuffer(e,t){const n=Jn(this,ti).getSize(),i=Jn(this,ui)*n.getDimSize(2);if(void 0===Jn(this,hi).numberOfFiles)throw new Error("Missing number of files for frame buffer manipulation.");const r=i*Jn(this,hi).numberOfFiles;Jn(this,ni).length!==r&&Kn(this,yi,Ti).call(this,r),t>=Jn(this,hi).numberOfFiles?re.warn("Ignoring frame at index "+t+" (size: "+Jn(this,hi).numberOfFiles+")"):(Jn(this,ni).set(e,i*t),this.appendFrame(t,new ke(0,0,0)))}appendFrame(e,t){Jn(this,ti).appendFrame(t,e),Jn(this,vi).call(this,{type:"appendframe"})}getDataRange(){return Jn(this,di)||$n(this,di,this.calculateDataRange()),Jn(this,di)}getRescaledDataRange(){return Jn(this,Si)||$n(this,Si,this.calculateRescaledDataRange()),Jn(this,Si)}getHistogram(){if(!Jn(this,gi)){const e=this.calculateHistogram();$n(this,di,e.dataRange),$n(this,Si,e.rescaledDataRange),$n(this,gi,e.histogram)}return Jn(this,gi)}addEventListener(e,t){Jn(this,pi).add(e,t)}removeEventListener(e,t){Jn(this,pi).remove(e,t)}setAtOffsets(e,t){let n;for(let i=0,r=e.length;i<r;++i)n=e[i],Jn(this,ni)[n]=t.r,Jn(this,ni)[n+1]=t.g,Jn(this,ni)[n+2]=t.b;Jn(this,vi).call(this,{type:"imagechange"})}setAtOffsetsAndGetOriginals(e,t){const n=[];for(let i=0;i<e.length;++i){const r=e[i];let a=3*r[0],o={r:Jn(this,ni)[a],g:Jn(this,ni)[a+1],b:Jn(this,ni)[a+2]};const s=[];s.push({index:0,colour:o});for(let e=0;e<r.length;++e){a=3*r[e];const n={r:Jn(this,ni)[a],g:Jn(this,ni)[a+1],b:Jn(this,ni)[a+2]};o.r===n.r&&o.g===n.g&&o.b===n.b||(s.push({index:e,colour:n}),o=n),Jn(this,ni)[a]=t.r,Jn(this,ni)[a+1]=t.g,Jn(this,ni)[a+2]=t.b}n.push(s)}return Jn(this,vi).call(this,{type:"imagechange"}),n}setAtOffsetsWithIterator(e,t){for(let n=0;n<e.length;++n){const i=e[n];let r;r=void 0!==t&&void 0!==t.r?Pi([{index:0,colour:t}],i.length):Pi(t[n],i.length);let a=r.next();for(;!a.done;){const e=3*i[a.index];Jn(this,ni)[e]=a.value.r,Jn(this,ni)[e+1]=a.value.g,Jn(this,ni)[e+2]=a.value.b,a=r.next()}}Jn(this,vi).call(this,{type:"imagechange"})}getValue(e,t,n,r){const a=new i([e,t,n,r||0]);return this.getValueAtOffset(this.getGeometry().getSize().indexToOffset(a))}getValueAtIndex(e){return this.getValueAtOffset(this.getGeometry().getSize().indexToOffset(e))}getRescaledValue(e,t,n,r){void 0===r&&(r=0);let a=this.getValue(e,t,n,r);if(!this.isIdentityRSI())if(this.isConstantRSI())a=this.getRescaleSlopeAndIntercept().apply(a);else{const o=new i([e,t,n,r]);a=this.getRescaleSlopeAndIntercept(o).apply(a)}return a}getRescaledValueAtIndex(e){return this.getRescaledValueAtOffset(this.getGeometry().getSize().indexToOffset(e))}getRescaledValueAtOffset(e){let t=this.getValueAtOffset(e);if(!this.isIdentityRSI())if(this.isConstantRSI())t=this.getRescaleSlopeAndIntercept().apply(t);else{const n=this.getGeometry().getSize().offsetToIndex(e);t=this.getRescaleSlopeAndIntercept(n).apply(t)}return t}calculateDataRange(){let e=this.getValueAtOffset(0),t=e,n=0;const i=this.getGeometry().getSize();let r=i.getTotalSize();i.length()>=3&&(r=i.getDimSize(3));for(let i=0;i<r;++i)n=this.getValueAtOffset(i),n>t&&(t=n),n<e&&(e=n);return{min:e,max:t}}calculateRescaledDataRange(){if(this.isIdentityRSI())return this.getDataRange();if(this.isConstantRSI()){const e=this.getDataRange(),t=this.getRescaleSlopeAndIntercept().apply(e.min),n=this.getRescaleSlopeAndIntercept().apply(e.max);return{min:t<n?t:n,max:t>n?t:n}}{let e=this.getRescaledValueAtOffset(0),t=e,n=0;const i=this.getGeometry().getSize();let r=i.getTotalSize();3===i.length()&&(r=i.getDimSize(3));for(let i=0;i<r;++i)n=this.getRescaledValueAtOffset(i),n>t&&(t=n),n<e&&(e=n);return{min:e,max:t}}}calculateHistogram(){const e=this.getGeometry().getSize(),t=[];let n=this.getValueAtOffset(0),i=n,r=0,a=this.getRescaledValueAtOffset(0),o=a,s=0;for(let l=0,c=e.getTotalSize();l<c;++l)r=this.getValueAtOffset(l),r>i&&(i=r),r<n&&(n=r),s=this.getRescaledValueAtOffset(l),s>o&&(o=s),s<a&&(a=s),t[s]=(t[s]||0)+1;const l={min:n,max:i},c={min:a,max:o},u=[];for(let e=a;e<=o;++e)u.push([e,t[e]||0]);return{dataRange:l,rescaledDataRange:c,histogram:u}}convolute2D(e){if(9!==e.length)throw new Error("The convolution matrix does not have a length of 9; it has "+e.length);const t=this.clone(),n=t.getBuffer(),i=this.getGeometry().getSize(),r=i.getDimSize(2)*this.getNumberOfComponents();for(let t=0;t<i.get(2);++t)this.convoluteBuffer(e,n,t*r);return t}convoluteBuffer(e,t,n){const i=this.getGeometry().getSize(),r=i.get(0),a=i.get(1),o=this.getNumberOfComponents();let s=1,l=1;3===o&&(0===this.getPlanarConfiguration()?s=3:l=i.getDimSize(2));const c=[];c[0]=(-r-1)*s,c[1]=-r*s,c[2]=(1-r)*s,c[3]=-s,c[4]=0,c[5]=1*s,c[6]=(r-1)*s,c[7]=r*s,c[8]=(r+1)*s;const u=[];u[0]=c[4],u[1]=c[4],u[2]=c[5],u[3]=c[4],u[4]=c[4],u[5]=c[5],u[6]=c[7],u[7]=c[7],u[8]=c[8];const h=[];h[0]=c[1],h[1]=c[1],h[2]=c[2],h[3]=c[4],h[4]=c[4],h[5]=c[5],h[6]=c[7],h[7]=c[7],h[8]=c[8];const d=[];d[0]=c[1],d[1]=c[1],d[2]=c[2],d[3]=c[4],d[4]=c[4],d[5]=c[5],d[6]=c[4],d[7]=c[4],d[8]=c[5];const S=[];S[0]=c[3],S[1]=c[4],S[2]=c[5],S[3]=c[3],S[4]=c[4],S[5]=c[5],S[6]=c[6],S[7]=c[7],S[8]=c[8];const g=[];g[0]=c[0],g[1]=c[1],g[2]=c[2],g[3]=c[3],g[4]=c[4],g[5]=c[5],g[6]=c[3],g[7]=c[4],g[8]=c[5];const p=[];p[0]=c[3],p[1]=c[4],p[2]=c[4],p[3]=c[3],p[4]=c[4],p[5]=c[4],p[6]=c[6],p[7]=c[7],p[8]=c[7];const f=[];f[0]=c[0],f[1]=c[1],f[2]=c[1],f[3]=c[3],f[4]=c[4],f[5]=c[4],f[6]=c[6],f[7]=c[7],f[8]=c[7];const m=[];m[0]=c[0],m[1]=c[1],m[2]=c[1],m[3]=c[3],m[4]=c[4],m[5]=c[4],m[6]=c[3],m[7]=c[4],m[8]=c[4];let y=n,v=0,D=[];for(let n=0;n<o;++n){y+=n*l;for(let n=0;n<a;++n)for(let i=0;i<r;++i){D=c,0===i&&0===n?D=u:0===i&&n===a-1?D=d:i===r-1&&0===n?D=p:i===r-1&&n===a-1?D=m:0===i&&n!==a-1&&0!==n?D=h:i===r-1&&n!==a-1&&0!==n?D=f:0!==i&&i!==r-1&&0===n?D=S:0!==i&&i!==r-1&&n===a-1&&(D=g),v=0;for(let t=0;t<9;++t)v+=this.getValueAtOffset(y+D[t])*e[t];t[y]=v,y+=s}}}transform(e){const t=this.clone(),n=t.getBuffer();for(let i=0,r=n.length;i<r;++i)n[i]=e(t.getValueAtOffset(i));return t}compose(e,t){const n=this.clone(),i=n.getBuffer();for(let n=0,r=i.length;n<r;++n)i[n]=Math.floor(t(this.getValueAtOffset(n),e.getValueAtOffset(n)));return n}}function wi(){return Jn(this,ti).getSize().getTotalSize(2)}function Ci(e){return Jn(this,ai)[e]}function Ti(e){let t=Jn(this,ni);if($n(this,ni,Yt(8*Jn(this,ni).BYTES_PER_ELEMENT,Jn(this,hi).IsSigned?1:0,e)),null===Jn(this,ni))throw new Error("Cannot reallocate data for image.");Jn(this,ni).set(t),t=null}function Ii(e,t,n,i,r,a,o,s){void 0===o&&(o=!1),void 0===s&&(s=!1);let l=t;o?(a*=-1,s?l-=(r-1)*i:i*=-1):s&&(l+=(r-1)*i,i*=-1);const c=a-r*i;let u=0,h=0;return{next:function(){if(u<n){const t={value:e(l),done:!1,index:l};return l+=i,++u,++h,h===r&&(h=0,l+=c),t}return{done:!0,index:l}}}}function Li(e){const t=[];let n=e.next();for(;!n.done;)t.push(n.value),n=e.next();return t}function bi(e,t,n,r){const a=e.getGeometry().getSize();let o=2;r&&void 0!==r&&(o=r.getColAbsMax(2).index);const s=t.getValues(),l=new i(s.map((function(e,t){return t===o||t>2?e:0})));let c=a.indexToOffset(l);void 0===n&&(n=!1);let u=null;u=n?function(t){return e.getRescaledValueAtOffset(t)}:function(t){return e.getValueAtOffset(t)};const h=a.get(0),d=a.get(1),S=a.get(2);let g=a.getDimSize(2);const p=e.getNumberOfComponents(),f=1===e.getPlanarConfiguration(),m=function(e,t,n,i,r,a,o,s){return 1===p?Ii(e,t,n,i,r,a,o,s):3===p?function(e,t,n,i,r,a,o,s,l){const c=[];return l?(c.push(Ii(e,t,n,i,r,a,o,s)),c.push(Ii(e,t+n*i,n,i,r,a,o,s)),c.push(Ii(e,t+2*n*i,n,i,r,a,o,s))):(i*=3,a*=3,c.push(Ii(e,t,n,i,r,a,o,s)),c.push(Ii(e,t+1,n,i,r,a,o,s)),c.push(Ii(e,t+2,n,i,r,a,o,s))),{next:function(){const e=c[0].next(),t=c[1].next(),n=c[2].next();return e.done?{done:!0,index:n.index}:{value:[e.value,t.value,n.value],done:!1,index:[e.index,t.index,n.index]}}}}(e,3*t,n,i,r,a,o,s,f):void 0};let y=null;if(r&&void 0!==r){const e=r.getColAbsMax(0),t=r.getColAbsMax(2),n=!1,i=!1;let a=null;if(2===t.index)a=h*d,y=0===e.index?m(u,c,a,1,h,h,n,i):m(u,c,a,h,d,1,n,i);else if(0===t.index)a=S*d,y=1===e.index?m(u,c,a,h,d,g,n,i):m(u,c,a,g,S,h,n,i);else{if(1!==t.index)throw new Error("Unknown direction: "+t.index);a=S*h,y=0===e.index?m(u,c,a,1,h,g,n,i):m(u,c,a,g,S,1,n,i)}}else if(1===e.getNumberOfComponents())y=function(e,t,n,i){void 0===i&&(i=1);let r=t;return{next:function(){if(r<n){const t={value:e(r),done:!1,index:r};return r+=i,t}return{done:!0,index:n}}}}(u,c,c+g);else{if(3!==e.getNumberOfComponents())throw new Error("Unsupported number of components: "+e.getNumberOfComponents());c*=3,g*=3,y=function(e,t,n,i,r){void 0===i&&(i=1),void 0===r&&(r=!1);let a=t,o=1;r?o=(n-t)/3:i*=3;let s=a+o,l=a+2*o;return{next:function(){if(a<n){const t={value:[e(a),e(s),e(l)],done:!1,index:[a,s,l]};return a+=i,s+=i,l+=i,t}return{done:!0,index:[n]}}}}(u,c,c+g,1,f)}return y}function Pi(e,t){let n=0,i=0;return{next:function(){if(n<t){i+1<e.length&&n>=e[i+1].index&&++i;const t={value:e[i].colour,done:!1,index:n};return++n,t}return{done:!0,index:t}}}}function Ai(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Oi(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Fi(e,t,"get"))}function xi(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Fi(e,t,"set"),n),n}function Fi(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}const Ri=["wlchange","wlpresetadd","colourchange","positionchange","opacitychange","alphafuncchange"];var Ei=new WeakMap,Mi=new WeakMap,qi=new WeakMap,Ui=new WeakMap,Qi=new WeakMap,ki=new WeakMap,Bi=new WeakMap,Ni=new WeakMap,Wi=new WeakMap,Vi=new WeakMap,Gi=new WeakMap;class zi{constructor(e){Ai(this,Ei,{writable:!0,value:void 0}),Ai(this,Mi,{writable:!0,value:{}}),Ai(this,qi,{writable:!0,value:{minmax:{name:"minmax"}}}),Ai(this,Ui,{writable:!0,value:null}),Ai(this,Qi,{writable:!0,value:null}),Ai(this,ki,{writable:!0,value:ie.plain}),Ai(this,Bi,{writable:!0,value:null}),Ai(this,Ni,{writable:!0,value:void 0}),Ai(this,Wi,{writable:!0,value:new wn}),Ai(this,Vi,{writable:!0,value:function(e,t){return 255}}),Ai(this,Gi,{writable:!0,value:e=>{Oi(this,Wi).fireEvent(e)}}),xi(this,Ei,e),Oi(this,Ei).addEventListener("appendframe",(()=>{const e=this.getCurrentIndex();if(3===e.length()){const t=e.getValues();t.push(0),this.setCurrentIndex(new i(t))}}))}getImage(){return Oi(this,Ei)}setImage(e){xi(this,Ei,e)}getOrientation(){return Oi(this,Ni)}setOrientation(e){xi(this,Ni,e)}init(){this.setInitialIndex()}setInitialIndex(){const e=Oi(this,Ei).getGeometry().getSize(),t=new Array(e.length());t.fill(0),t[0]=Math.floor(e.get(0)/2),t[1]=Math.floor(e.get(1)/2),t[2]=Math.floor(e.get(2)/2),this.setCurrentIndex(new i(t),!0)}getPlaybackMilliseconds(e){return e||(e=10),Math.round(1e3/e)}getAlphaFunction(){return Oi(this,Vi)}setAlphaFunction(e){xi(this,Vi,e),Oi(this,Gi).call(this,{type:"alphafuncchange"})}getCurrentWindowLut(e){this.getCurrentIndex()||this.setInitialIndex();const t=this.getCurrentIndex();void 0===e&&(e=Oi(this,Ei).getRescaleSlopeAndIntercept(t));let n=null;if(Oi(this,Ui)&&void 0!==Oi(this,qi)[Oi(this,Ui)]&&void 0!==Oi(this,qi)[Oi(this,Ui)].perslice&&!0===Oi(this,qi)[Oi(this,Ui)].perslice){const e=Oi(this,Ei).getSecondaryOffset(t);n=Oi(this,qi)[Oi(this,Ui)].wl[e]}n||(Oi(this,Qi)||this.setWindowLevelPresetById(0,!0),n=Oi(this,Qi));let i=Oi(this,Mi)[e.toString()];if(void 0===i){const e=new C(Oi(this,Ei).getRescaleSlopeAndIntercept(),Oi(this,Ei).getMeta().BitsStored),t=new J(e,Oi(this,Ei).getMeta().IsSigned);this.addWindowLut(t),i=t}const r=i.getWindowLevel();return n.equals(r)||(i.setWindowLevel(n),i.update(),r&&r.getWidth()===n.getWidth()&&r.getCenter()===n.getCenter()||Oi(this,Gi).call(this,{type:"wlchange",value:[n.getCenter(),n.getWidth()],wc:n.getCenter(),ww:n.getWidth(),skipGenerate:!0})),i}addWindowLut(e){const t=e.getRescaleLut().getRSI();Oi(this,Mi)[t.toString()]=e}getWindowPresets(){return Oi(this,qi)}getWindowPresetsNames(){return Object.keys(Oi(this,qi))}setWindowPresets(e){xi(this,qi,e)}setDefaultColourMap(e){xi(this,ki,e)}addWindowPresets(e){const t=Object.keys(e);let n=null;for(let i=0;i<t.length;++i)if(n=t[i],void 0!==Oi(this,qi)[n]){if(void 0!==Oi(this,qi)[n].perslice&&!0===Oi(this,qi)[n].perslice)throw new Error("Cannot add perslice preset");Oi(this,qi)[n]=e[n]}else Oi(this,qi)[n]=e[n],Oi(this,Gi).call(this,{type:"wlpresetadd",name:n})}getColourMap(){return Oi(this,ki)}setColourMap(e){xi(this,ki,e),Oi(this,Gi).call(this,{type:"colourchange",wc:this.getCurrentWindowLut().getWindowLevel().getCenter(),ww:this.getCurrentWindowLut().getWindowLevel().getWidth()})}getCurrentPosition(){return Oi(this,Bi)}getCurrentIndex(){const e=this.getCurrentPosition();return e?this.getImage().getGeometry().worldToIndex(e):null}canSetPosition(e){const t=Oi(this,Ei).getGeometry(),n=t.worldToIndex(e),i=[this.getScrollIndex()];return 4===n.length()&&i.push(3),t.isIndexInBounds(n,i)}getOrigin(e){const t=Oi(this,Ei).getGeometry();let n=0;return void 0!==e&&(n=t.worldToIndex(e).get(2)),t.getOrigins()[n]}setCurrentPosition(e,t){const n=Oi(this,Ei).getGeometry(),i=n.worldToIndex(e),r=[this.getScrollIndex()];return 4===i.length()&&r.push(3),n.isIndexInBounds(i,r)?this.setCurrentIndex(i,t):(t||Oi(this,Gi).call(this,{type:"positionchange",value:[i.getValues(),e.getValues()],valid:!1}),!1)}setCurrentIndex(e,t){void 0===t&&(t=!1);const n=Oi(this,Ei).getGeometry(),i=n.indexToWorld(e),r=[this.getScrollIndex()];if(4===e.length()&&r.push(3),!n.isIndexInBounds(e,r))return!1;let a=null,o=null;if(this.getCurrentPosition()&&(o=this.getCurrentIndex()),o)if(o.canCompare(e))a=o.compare(e);else{a=[];const t=Math.min(o.length(),e.length());for(let n=0;n<t;++n)o.get(n)!==e.get(n)&&a.push(n);const n=Math.max(o.length(),e.length());for(let e=t;e<n;++e)a.push(e)}else{a=[];for(let t=0;t<e.length();++t)a.push(t)}if(xi(this,Bi,i),!t){const t={type:"positionchange",value:[e.getValues(),i.getValues()],diffDims:a,data:{imageUid:Oi(this,Ei).getImageUid(e)}};if(Oi(this,Ei).canQuantify()){const n=Oi(this,Ei).getRescaledValueAtIndex(e);t.value.push(n)}Oi(this,Gi).call(this,t)}return!0}setWindowLevel(e,t,n,i){if(t<1)return;void 0===n&&(n="manual"),void 0===i&&(i=!1);const r=new N(e,t);if(!r.equals(Oi(this,Qi))){const a=!Oi(this,Qi)||Oi(this,Qi).getWidth()!==t,o=!Oi(this,Qi)||Oi(this,Qi).getCenter()!==e;xi(this,Qi,r),xi(this,Ui,n),(a||o)&&Oi(this,Gi).call(this,{type:"wlchange",value:[e,t],wc:e,ww:t,skipGenerate:i})}}setWindowLevelPreset(e,t){const n=this.getWindowPresets()[e];if(void 0===n)throw new Error("Unknown window level preset: '"+e+"'");"minmax"===e&&void 0===n.wl&&(n.wl=[this.getWindowLevelMinMax()]);let i=n.wl[0];if(void 0!==n.perslice&&!0===n.perslice){const e=Oi(this,Ei).getSecondaryOffset(this.getCurrentIndex());i=n.wl[e]}this.setWindowLevel(i.getCenter(),i.getWidth(),e,t)}setWindowLevelPresetById(e,t){const n=Object.keys(this.getWindowPresets());this.setWindowLevelPreset(n[e],t)}addEventListener(e,t){Oi(this,Wi).add(e,t)}removeEventListener(e,t){Oi(this,Wi).remove(e,t)}getWindowLevelMinMax(){const e=this.getImage().getRescaledDataRange(),t=e.min;let n=e.max-t;return n<1&&(re.warn("Zero or negative window width, defaulting to one."),n=1),new N(t+n/2,n)}setWindowLevelMinMax(){const e=this.getWindowLevelMinMax();this.setWindowLevel(e.getCenter(),e.getWidth(),"minmax")}generateImageData(e,t){void 0===t&&(this.getCurrentIndex()||this.setInitialIndex(),t=this.getCurrentIndex());const n=this.getImage(),i=bi(n,t,!1,this.getOrientation()),r=n.getPhotometricInterpretation();switch(r){case"MONOCHROME1":case"MONOCHROME2":!function(e,t,n,i,r){let a=0,o=0,s=t.next();for(;!s.done;)o=i.getValue(s.value),e.data[a]=r.red[o],e.data[a+1]=r.green[o],e.data[a+2]=r.blue[o],e.data[a+3]=n(s.value,s.index),a+=4,s=t.next()}(e,i,this.getAlphaFunction(),this.getCurrentWindowLut(),this.getColourMap());break;case"PALETTE COLOR":!function(e,t,n,i,r){const a=function(e){return e>>8};r&&re.info("Scaling 16bits data to 8bits.");let o=0,s=0,l=t.next();for(;!l.done;)s=l.value,r?(e.data[o]=a(i.red[s]),e.data[o+1]=a(i.green[s]),e.data[o+2]=a(i.blue[s])):(e.data[o]=i.red[s],e.data[o+1]=i.green[s],e.data[o+2]=i.blue[s]),e.data[o+3]=n(s,l.index),o+=4,l=t.next()}(e,i,this.getAlphaFunction(),this.getColourMap(),16===n.getMeta().BitsStored);break;case"RGB":!function(e,t,n){let i=0,r=t.next();for(;!r.done;)e.data[i]=r.value[0],e.data[i+1]=r.value[1],e.data[i+2]=r.value[2],e.data[i+3]=n(r.value,r.index),i+=4,r=t.next()}(e,i,this.getAlphaFunction());break;case"YBR_FULL":!function(e,t,n){let i=0,r=null,a=t.next();for(;!a.done;)o=a.value[0],s=a.value[1],r={r:o+1.402*((l=a.value[2])-128),g:o-.34414*(s-128)-.71414*(l-128),b:o+1.772*(s-128)},e.data[i]=r.r,e.data[i+1]=r.g,e.data[i+2]=r.b,e.data[i+3]=n(a.value,a.index),i+=4,a=t.next();var o,s,l}(e,i,this.getAlphaFunction());break;default:throw new Error("Unsupported photometric interpretation: "+r)}}incrementIndex(e,t){const n=this.getCurrentIndex(),r=new Array(n.length());r.fill(0),e<r.length?r[e]=1:console.warn("Cannot increment given index: ",e,r.length);const a=new i(r),o=n.add(a);return this.setCurrentIndex(o,t)}decrementIndex(e,t){const n=this.getCurrentIndex(),r=new Array(n.length());r.fill(0),e<r.length?r[e]=-1:console.warn("Cannot decrement given index: ",e,r.length);const a=new i(r),o=n.add(a);return this.setCurrentIndex(o,t)}getScrollIndex(){let e=null;const t=this.getOrientation();return e=void 0!==t?t.getThirdColMajorDirection():2,e}decrementScrollIndex(e){return this.decrementIndex(this.getScrollIndex(),e)}incrementScrollIndex(e){return this.incrementIndex(this.getScrollIndex(),e)}}class Hi{create(e,t){const n=new zi(t);if("MONOCHROME1"===t.getPhotometricInterpretation())n.setDefaultColourMap(ie.invPlain);else if("PALETTE COLOR"===t.getPhotometricInterpretation()){const e=t.getMeta().paletteLut;void 0!==e&&n.setDefaultColourMap(e)}let i={};if(void 0!==t.getMeta().windowPresets&&(i=t.getMeta().windowPresets),i.minmax={name:"minmax"},void 0!==O){const e=t.getMeta().Modality;for(const t in O[e]){const n=O[e][t];i[t]={wl:[new N(n.center,n.width)],name:t}}}return n.setWindowPresets(i),n.init(),n}}function ji(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Xi(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,_i(e,t,"get"))}function Yi(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,_i(e,t,"set"),n),n}function _i(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Zi=new WeakMap,Ki=new WeakMap,Ji=new WeakMap,$i=new WeakMap;class er{constructor(e,t,n){ji(this,Zi,{writable:!0,value:void 0}),ji(this,Ki,{writable:!0,value:void 0}),ji(this,Ji,{writable:!0,value:void 0}),ji(this,$i,{writable:!0,value:void 0}),Yi(this,Zi,e),Yi(this,Ki,t),Yi(this,Ji,n),Yi(this,$i,function(e,t){let n=e.asOneAndZeros().multiply(t);return e.asOneAndZeros().getAbs().equals(be().getAbs())&&(n=n.getAbs()),n}(t,n))}getOffset3DFromPlaneOffset(e){const t=new pe(e.x,e.y,0),n=this.getTargetDeOrientedVector3D(t);return new pe(n.getX()*Xi(this,Zi).get(0),n.getY()*Xi(this,Zi).get(1),n.getZ()*Xi(this,Zi).get(2))}getPlaneOffsetFromOffset3D(e){const t=new pe(e.x/Xi(this,Zi).get(0),e.y/Xi(this,Zi).get(1),e.z/Xi(this,Zi).get(2)),n=this.getTargetOrientedVector3D(t);return{x:n.getX(),y:n.getY()}}getTargetOrientedVector3D(e){let t=e;return void 0!==Xi(this,$i)&&(t=Xi(this,$i).getInverse().multiplyVector3D(e)),t}getTargetDeOrientedVector3D(e){let t=e;return void 0!==Xi(this,$i)&&(t=Xi(this,$i).multiplyVector3D(e)),t}getTargetDeOrientedPoint3D(e){let t=e;return void 0!==Xi(this,$i)&&(t=Xi(this,$i).multiplyPoint3D(e)),t}getImageOrientedVector3D(e){let t=e;if(void 0!==Xi(this,Ji)){const n=jn([e.getX(),e.getY(),e.getZ()],Xi(this,Ji));t=new pe(n[0],n[1],n[2])}return t}getImageOrientedPoint3D(e){let t=e;if(void 0!==Xi(this,Ji)){const n=jn([e.getX(),e.getY(),e.getZ()],Xi(this,Ji));t=new ke(n[0],n[1],n[2])}return t}getImageDeOrientedVector3D(e){let t=e;if(void 0!==Xi(this,Ji)){const n=Hn([e.getX(),e.getY(),e.getZ()],Xi(this,Ji));t=new pe(n[0],n[1],n[2])}return t}getImageDeOrientedPoint3D(e){let t=e;if(void 0!==Xi(this,Ji)){const n=Hn([e.getX(),e.getY(),e.getZ()],Xi(this,Ji));t=new ke(n[0],n[1],n[2])}return t}getTargetOrientedPositiveXYZ(e){const t=Hn([e.x,e.y,e.z],Xi(this,$i));return{x:t[0],y:t[1],z:t[2]}}getScrollIndex(){let e=null;return e=void 0!==Xi(this,Ji)?Xi(this,Ji).getThirdColMajorDirection():2,e}getNativeScrollIndex(){let e=null;return e=void 0!==Xi(this,Ki)?Xi(this,Ki).getThirdColMajorDirection():2,e}}function tr(e,t,n){nr(e,t),t.set(e,n)}function nr(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function ir(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function rr(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,or(e,t,"get"))}function ar(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,or(e,t,"set"),n),n}function or(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var sr=new WeakMap,lr=new WeakMap,cr=new WeakMap,ur=new WeakSet;class hr{constructor(e){var t;nr(this,t=ur),t.add(this),tr(this,sr,{writable:!0,value:void 0}),tr(this,lr,{writable:!0,value:void 0}),tr(this,cr,{writable:!0,value:[]}),ar(this,sr,e),ar(this,lr,e.getMeta().custom.segments)}hasSegment(e){return void 0!==this.getSegment(e)}maskHasSegments(e){const t=[],n=[];for(let i=0;i<e.length;++i){const r=this.getSegment(e[i]);void 0!==r?t.push(r.displayValue):(re.warn("Unknown segment in maskHasSegments: "+e[i]),n.push(i))}const i=rr(this,sr).hasValues(t);for(let e=0;e<n.length;++e)i.splice(n[e],0,!1);return i}getSegment(e){return rr(this,lr).find((function(t){return t.number===e}))}getSegments(){return rr(this,lr)}setSegments(e){ar(this,lr,e)}setHiddenSegments(e){ar(this,cr,e)}isHidden(e){return-1!==ir(this,ur,dr).call(this,e)}addToHidden(e){this.isHidden(e)?re.warn("Segment is allready in the hidden list: "+e):rr(this,cr).push(e)}removeFromHidden(e){const t=ir(this,ur,dr).call(this,e);-1!==t?rr(this,cr).splice(t,1):re.warn("Segment is not in the hidden list: "+e)}getAlphaFunc(){const e=[{r:0,g:0,b:0}];for(let t=0;t<rr(this,cr).length;++t){const n=this.getSegment(rr(this,cr)[t]);void 0!==n&&e.push(n.displayValue)}return function(t){for(let n=0;n<e.length;++n)if(t[0]===e[n].r&&t[1]===e[n].g&&t[2]===e[n].b)return 0;return 255}}deleteSegment(e,t,n){const i=new mr(rr(this,sr),this.getSegment(e));i.onExecute=t,i.onUndo=t,i.isValid()&&(i.execute(),n(i),this.isHidden(e)&&this.removeFromHidden(e))}}function dr(e){return rr(this,cr).findIndex((function(t){return t===e}))}var Sr=new WeakMap,gr=new WeakMap,pr=new WeakMap,fr=new WeakMap;class mr{constructor(e,t,n){tr(this,Sr,{writable:!0,value:void 0}),tr(this,gr,{writable:!0,value:void 0}),tr(this,pr,{writable:!0,value:void 0}),tr(this,fr,{writable:!0,value:void 0}),ar(this,Sr,e),ar(this,gr,t),ar(this,pr,void 0!==n&&n),ar(this,fr,e.getOffsets(t.displayValue))}getName(){return"Delete-segment"}isValid(){return 0!==rr(this,fr).length}execute(){rr(this,Sr).setAtOffsets(rr(this,fr),{r:0,g:0,b:0}),rr(this,pr)||this.onExecute({type:"masksegmentdelete",segmentnumber:rr(this,gr).number})}undo(){rr(this,Sr).setAtOffsets(rr(this,fr),rr(this,gr).displayValue),this.onUndo({type:"masksegmentredraw",segmentnumber:rr(this,gr).number})}onExecute(e){}onUndo(e){}}function yr(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function vr(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,wr(e,t,"get"))}function Dr(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,wr(e,t,"set"),n),n}function wr(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Cr=new WeakMap,Tr=new WeakMap,Ir=new WeakMap,Lr=new WeakMap,br=new WeakMap,Pr=new WeakMap,Ar=new WeakMap,Or=new WeakMap;class xr{constructor(e,t){if(yr(this,Cr,{writable:!0,value:void 0}),yr(this,Tr,{writable:!0,value:void 0}),yr(this,Ir,{writable:!0,value:void 0}),yr(this,Lr,{writable:!0,value:void 0}),yr(this,br,{writable:!0,value:null}),yr(this,Pr,{writable:!0,value:void 0}),yr(this,Ar,{writable:!0,value:new wn}),yr(this,Or,{writable:!0,value:e=>{e.dataid=vr(this,Pr),vr(this,Ar).fireEvent(e)}}),void 0===e.getImage())throw new Error("View does not have an image, cannot setup controller");Dr(this,Cr,e),Dr(this,Tr,t),Dr(this,Ir,new er(e.getImage().getGeometry().getRealSpacing(),e.getImage().getGeometry().getOrientation(),e.getOrientation())),"SEG"===e.getImage().getMeta().Modality&&Dr(this,Lr,new hr(e.getImage()))}getPlaneHelper(){return vr(this,Ir)}isMask(){return void 0!==vr(this,Lr)}getMaskSegmentHelper(){return vr(this,Lr)}applyHiddenSegments(){this.isMask&&this.setViewAlphaFunction(vr(this,Lr).getAlphaFunc())}deleteSegment(e,t){this.isMask&&vr(this,Lr).deleteSegment(e,vr(this,Or),t)}initialise(){this.setWindowLevelPresetById(0),this.setCurrentPosition(this.getPositionFromPlanePoint(0,0))}getWindowLevelPresetsNames(){return vr(this,Cr).getWindowPresetsNames()}addWindowLevelPresets(e){return vr(this,Cr).addWindowPresets(e)}setWindowLevelPreset(e){vr(this,Cr).setWindowLevelPreset(e)}setWindowLevelPresetById(e){vr(this,Cr).setWindowLevelPresetById(e)}isPlaying(){return null!==vr(this,br)}getCurrentPosition(){return vr(this,Cr).getCurrentPosition()}getCurrentIndex(){return vr(this,Cr).getCurrentIndex()}getCurrentOrientedIndex(){let e=vr(this,Cr).getCurrentIndex();if(void 0!==vr(this,Cr).getOrientation()){const t=vr(this,Ir).getImageDeOrientedVector3D(new pe(e.get(0),e.get(1),e.get(2)));e=new i([t.getX(),t.getY(),t.getZ()])}return e}getScrollIndex(){return vr(this,Cr).getScrollIndex()}getCurrentScrollIndexValue(){return vr(this,Cr).getCurrentIndex().get(vr(this,Cr).getScrollIndex())}getOrigin(e){return vr(this,Cr).getOrigin(e)}getCurrentScrollPosition(){const e=vr(this,Cr).getScrollIndex();return vr(this,Cr).getCurrentPosition().get(e)}generateImageData(e,t){vr(this,Cr).generateImageData(e,t)}setImage(e,t){vr(this,Cr).setImage(e),Dr(this,Pr,t)}get2DSpacing(){const e=vr(this,Cr).getImage().getGeometry().getSpacing();return[e.get(0),e.get(1)]}getRescaledImageValue(e){const t=vr(this,Cr).getImage();if(!t.canQuantify())return;const n=t.getGeometry(),i=n.worldToIndex(e);let r;return n.isIndexInBounds(i)&&(r=t.getRescaledValueAtIndex(i)),r}getPixelUnit(){return vr(this,Cr).getImage().getMeta().pixelUnit}getImageRegionValues(e,t){let n=vr(this,Cr).getImage();const r=vr(this,Cr).getOrientation();let a=this.getCurrentIndex(),o=!0;if(!r.equals(Le())){const e=Li(bi(n,a,o,r)),t=n.getGeometry().getSize(r).getValues();t[2]=1;const s=new Ln(t),l=n.getGeometry().getSpacing(r).getValues();l[2]=1;const c=new On(l),u=new ke(0,0,0),h=new Gn(u,s,c);n=new Di(h,e),a=new i([0,0,0]),o=!1}const s=function(e,t,n,i,r){if(1!==e.getNumberOfComponents())throw new Error("Unsupported number of components for region iterator: "+e.getNumberOfComponents());void 0===n&&(n=!1);let a=null;a=n?function(t){return e.getRescaledValueAtOffset(t)}:function(t){return e.getValueAtOffset(t)};const o=e.getGeometry().getSize();void 0===i&&(i=new Me(0,0)),void 0===r&&(r=new Me(o.get(0)-1,o.get(1)));const s=o.indexToOffset(t.getWithNew2D(i.getX(),i.getY())),l=o.indexToOffset(t.getWithNew2D(r.getX(),r.getY()-1)),c=Math.max(1,r.getX()-i.getX());return function(e,t,n,i,r,a){let o=t,s=0;return{next:function(){if(o<n){const t={value:e(o),done:!1,index:o};return s+=1,o+=1,s===r&&(s=0,o+=a),t}return{done:!0,index:n}}}}(a,s,l+1,0,c,o.get(0)-c)}(n,a,o,e,t);let l=[];return s&&(l=Li(s)),l}getImageVariableRegionValues(e){const t=function(e,t,n,i){if(1!==e.getNumberOfComponents())throw new Error("Unsupported number of components for region iterator: "+e.getNumberOfComponents());void 0===n&&(n=!1);let r=null;r=n?function(t){return e.getRescaledValueAtOffset(t)}:function(t){return e.getValueAtOffset(t)};const a=e.getGeometry().getSize(),o=[];let s,l=null,c=null,u=null;for(let e=0;e<i.length;++e){s=i[e];const t=s[1][0]-s[0][0];0!==t&&(u=e,l||(l=s[0]),o.push([s[0][0],t,a.get(0)-s[1][0]]))}if(null!==u&&(c=i[u][1]),0!==o.length)return function(e,t,n,i,r){let a=t,o=0,s=0;return{next:function(){if(a<n){const t={value:e(a),done:!1,index:a};return s+=1,a+=1,s===r[o][1]&&(s=0,a+=r[o][2],o+=1,o<r.length&&(a+=r[o][0])),t}return{done:!0,index:n}}}}(r,a.indexToOffset(t.getWithNew2D(l[0],l[1])),a.indexToOffset(t.getWithNew2D(c[0],c[1]))+1,0,o)}(vr(this,Cr).getImage(),this.getCurrentIndex(),!0,e);let n=[];return t&&(n=Li(t)),n}canQuantifyImage(){return vr(this,Cr).getImage().canQuantify()}canWindowLevel(){return vr(this,Cr).getImage().canWindowLevel()}canScroll(){return vr(this,Cr).getImage().canScroll(vr(this,Cr).getOrientation())}getImageSize(){return vr(this,Cr).getImage().getGeometry().getSize(vr(this,Cr).getOrientation())}getImageWorldSize(){const e=vr(this,Cr).getImage().getGeometry(),t=e.getSize(vr(this,Cr).getOrientation()).get2D(),n=e.getSpacing(vr(this,Cr).getOrientation()).get2D();return{x:t.x*n.x,y:t.y*n.y}}getImageRescaledDataRange(){return vr(this,Cr).getImage().getRescaledDataRange()}equalImageMeta(e){const t=vr(this,Cr).getImage().getMeta(),n=Object.keys(e);for(let i=0;i<n.length;++i){const r=n[i];if(void 0===t[r])return!1;if(t[r]!==e[r])return!1}return!0}canSetPosition(e){return vr(this,Cr).canSetPosition(e)}setCurrentPosition(e,t){return vr(this,Cr).setCurrentPosition(e,t)}getPositionFromPlanePoint(e,t){const n=this.getCurrentScrollIndexValue(),i=new ke(e,t,n),r=vr(this,Ir).getImageOrientedPoint3D(i),a=vr(this,Cr).getImage().getGeometry().pointToWorld(r);return this.getCurrentPosition().mergeWith3D(a)}getPlanePositionFromPosition(e){const t=vr(this,Cr).getImage().getGeometry().worldToPoint(e),n=vr(this,Ir).getImageDeOrientedPoint3D(t);return{x:n.getX(),y:n.getY()}}setCurrentIndex(e,t){return vr(this,Cr).setCurrentIndex(e,t)}getPlanePositionFromPlanePoint(e){const t=this.getCurrentScrollIndexValue(),n=new ke(e.x,e.y,t),i=vr(this,Ir).getTargetDeOrientedPoint3D(n),r=vr(this,Cr).getImage().getGeometry().getRealSpacing();return new ke(i.getX()*r.get(0),i.getY()*r.get(1),i.getZ()*r.get(2))}getOffset3DFromPlaneOffset(e){return vr(this,Ir).getOffset3DFromPlaneOffset(e)}incrementIndex(e,t){return vr(this,Cr).incrementIndex(e,t)}decrementIndex(e,t){return vr(this,Cr).decrementIndex(e,t)}decrementScrollIndex(e){return vr(this,Cr).decrementScrollIndex(e)}incrementScrollIndex(e){return vr(this,Cr).incrementScrollIndex(e)}play(){if(this.canScroll())if(null===vr(this,br)){const e=vr(this,Cr).getImage(),t=e.getMeta().RecommendedDisplayFrameRate,n=vr(this,Cr).getPlaybackMilliseconds(t),r=e.getGeometry().getSize().canScroll3D();Dr(this,br,setInterval((()=>{let e=!1;if(e=r?this.incrementScrollIndex():this.incrementIndex(3),!e){const e=this.getCurrentIndex().getValues(),t=vr(this,Cr).getOrientation();r?e[t.getThirdColMajorDirection()]=0:e[3]=0;const n=new i(e),a=vr(this,Cr).getImage().getGeometry();this.setCurrentPosition(a.indexToWorld(n))}}),n))}else this.stop()}stop(){null!==vr(this,br)&&(clearInterval(vr(this,br)),Dr(this,br,null))}getWindowLevel(){return{width:vr(this,Cr).getCurrentWindowLut().getWindowLevel().getWidth(),center:vr(this,Cr).getCurrentWindowLut().getWindowLevel().getCenter()}}setWindowLevel(e,t){vr(this,Cr).setWindowLevel(e,t)}getColourMap(){return vr(this,Cr).getColourMap()}setColourMap(e){vr(this,Cr).setColourMap(e)}setViewAlphaFunction(e){vr(this,Cr).setAlphaFunction(e)}setColourMapFromName(e){if(!ie[e])throw new Error("Unknown colour map: '"+e+"'");this.setColourMap(ie[e])}addEventListener(e,t){vr(this,Ar).add(e,t)}removeEventListener(e,t){vr(this,Ar).remove(e,t)}}const Fr=["mousedown","mousemove","mouseup","mouseout","wheel","dblclick","touchstart","touchmove","touchend"];function Rr(e,t){return Rr(e,t)}const Er={};function Mr(e){let t=0,n=0;if(0!==e.length&&void 0!==e[0].target){let i=e[0].target.offsetParent;for(;i;)isNaN(i.offsetLeft)||(t+=i.offsetLeft),isNaN(i.offsetTop)||(n+=i.offsetTop),i=i.offsetParent}else re.debug("No touch target offset parent.");const i=[];for(let r=0;r<e.length;++r)i.push({x:e[r].pageX-t,y:e[r].pageY-n});return i}function qr(e){let t=[];return void 0!==e.targetTouches&&0!==e.targetTouches.length?t=Mr(e.targetTouches):void 0!==e.changedTouches&&0!==e.changedTouches.length?t=Mr(e.changedTouches):t.push({x:e.offsetX,y:e.offsetY}),t}function Ur(e,t){const n=document.createElement("canvas");n.width=e,n.height=t;const i=document.createElement("canvas");i.width=1,i.height=1;const r=n.getContext("2d"),a=i.getContext("2d");return r&&(r.fillRect(e-1,t-1,1,1),a.drawImage(n,e-1,t-1,1,1,0,0,1,1)),a&&0!==a.getImageData(0,0,1,1).data[3]}function Qr(e,t){Nr(e,t),t.add(e)}function kr(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Br(e,t,n){Nr(e,t),t.set(e,n)}function Nr(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Wr(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Vr(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,zr(e,t,"get"))}function Gr(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,zr(e,t,"set"),n),n}function zr(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Hr=new WeakMap,jr=new WeakMap,Xr=new WeakMap,Yr=new WeakMap,_r=new WeakMap,Zr=new WeakMap,Kr=new WeakMap,Jr=new WeakMap,$r=new WeakMap,ea=new WeakMap,ta=new WeakMap,na=new WeakMap,ia=new WeakMap,ra=new WeakMap,aa=new WeakMap,oa=new WeakMap,sa=new WeakMap,la=new WeakMap,ca=new WeakMap,ua=new WeakMap,ha=new WeakMap,da=new WeakSet,Sa=new WeakMap,ga=new WeakSet,pa=new WeakMap,fa=new WeakMap,ma=new WeakMap,ya=new WeakMap;class va{constructor(e){Qr(this,ga),Qr(this,da),Br(this,Hr,{writable:!0,value:void 0}),Br(this,jr,{writable:!0,value:null}),Br(this,Xr,{writable:!0,value:null}),Br(this,Yr,{writable:!0,value:null}),Br(this,_r,{writable:!0,value:null}),Br(this,Zr,{writable:!0,value:!0}),Br(this,Kr,{writable:!0,value:null}),Br(this,Jr,{writable:!0,value:void 0}),Br(this,$r,{writable:!0,value:void 0}),Br(this,ea,{writable:!0,value:1}),Br(this,ta,{writable:!0,value:{x:1,y:1}}),Br(this,na,{writable:!0,value:{x:1,y:1}}),Br(this,ia,{writable:!0,value:{x:0,y:0}}),Br(this,ra,{writable:!0,value:{x:0,y:0}}),Br(this,aa,{writable:!0,value:{x:0,y:0}}),Br(this,oa,{writable:!0,value:{x:0,y:0}}),Br(this,sa,{writable:!0,value:{x:0,y:0}}),Br(this,la,{writable:!0,value:null}),Br(this,ca,{writable:!0,value:null}),Br(this,ua,{writable:!0,value:new wn}),Br(this,ha,{writable:!0,value:!1}),kr(this,"onimageset",(e=>{Vr(this,ca)===e.dataid&&(Vr(this,jr).setImage(e.value[0],Vr(this,ca)),Wr(this,da,Da).call(this,Vr(this,jr).getImageSize().get2D()),Gr(this,la,!0))})),kr(this,"onimagechange",(e=>{Vr(this,ca)===e.dataid&&Gr(this,la,!0)})),Br(this,Sa,{writable:!0,value:e=>{e.srclayerid=this.getId(),e.dataid=Vr(this,ca),Vr(this,ua).fireEvent(e)}}),Br(this,pa,{writable:!0,value:e=>{void 0!==e.skipGenerate&&!0===e.skipGenerate||(Gr(this,la,!0),this.draw())}}),Br(this,fa,{writable:!0,value:e=>{void 0!==e.skipGenerate&&!0===e.skipGenerate||(Gr(this,la,!0),this.draw())}}),Br(this,ma,{writable:!0,value:e=>{if(void 0===e.skipGenerate||!0!==e.skipGenerate){let t=!0;if(void 0!==e.valid&&(t=e.valid),t){const t=[0,1,2],n=t.indexOf(Vr(this,jr).getScrollIndex());t.splice(n,1),0===e.diffDims.filter((function(e){return-1===t.indexOf(e)})).length&&Vr(this,Zr)||(Gr(this,Zr,!0),Gr(this,la,!0),this.draw())}else Vr(this,Zr)&&(Gr(this,Zr,!1),this.clear())}}}),Br(this,ya,{writable:!0,value:e=>{void 0!==e.skipGenerate&&!0===e.skipGenerate||(Gr(this,la,!0),this.draw())}}),Gr(this,Hr,e),Vr(this,Hr).className+=" viewLayer"}getDataIndex(){return Vr(this,ca)}enableImageSmoothing(e){Gr(this,ha,e)}setView(e,t){Gr(this,ca,t),e.addEventListener("wlchange",Vr(this,pa)),e.addEventListener("colourchange",Vr(this,fa)),e.addEventListener("positionchange",Vr(this,ma)),e.addEventListener("alphafuncchange",Vr(this,ya));for(let t=0;t<Ri.length;++t)e.addEventListener(Ri[t],Vr(this,Sa));Gr(this,jr,new xr(e,t))}getViewController(){return Vr(this,jr)}getImageData(){return Vr(this,Kr)}getId(){return Vr(this,Hr).id}getBaseSize(){return Vr(this,Jr)}getImageWorldSize(){return Vr(this,jr).getImageWorldSize()}getOpacity(){return Vr(this,ea)}setOpacity(e){if(e===Vr(this,ea))return;Gr(this,ea,Math.min(Math.max(e,0),1));const t={type:"opacitychange",value:[Vr(this,ea)]};Vr(this,Sa).call(this,t)}addFlipOffsetX(){Vr(this,sa).x+=Vr(this,Xr).width/Vr(this,ta).x,Vr(this,ia).x+=Vr(this,sa).x}addFlipOffsetY(){Vr(this,sa).y+=Vr(this,Xr).height/Vr(this,ta).y,Vr(this,ia).y+=Vr(this,sa).y}setScale(e,t){const n=Vr(this,jr).getPlaneHelper(),i=n.getTargetOrientedPositiveXYZ(e),r={x:Vr(this,na).x*i.x,y:Vr(this,na).y*i.y};if(1===Math.abs(e.x)&&1===Math.abs(e.y)&&1===Math.abs(e.z)){const e={x:Vr(this,ia).x-Vr(this,oa).x,y:Vr(this,ia).y-Vr(this,oa).y};Gr(this,oa,{x:0,y:0}),Gr(this,ia,e)}else if(void 0!==t){let e=n.getPlaneOffsetFromOffset3D({x:t.getX(),y:t.getY(),z:t.getZ()});e={x:e.x+Vr(this,ra).x,y:e.y+Vr(this,ra).y};const i=rs(Vr(this,ia),Vr(this,ta),r,e),a={x:Vr(this,oa).x+i.x-Vr(this,ia).x,y:Vr(this,oa).y+i.y-Vr(this,ia).y};Gr(this,oa,a),Gr(this,ia,i)}Gr(this,ta,r)}setBaseOffset(e,t){const n=Vr(this,jr).getPlaneHelper(),i=n.getNativeScrollIndex(),r=n.getPlaneOffsetFromOffset3D({x:0===i?e.getX():t.getX(),y:1===i?e.getY():t.getY(),z:2===i?e.getZ():t.getZ()}),a=Vr(this,ra).x!==r.x||Vr(this,ra).y!==r.y;return a&&(Gr(this,ia,{x:Vr(this,ia).x-Vr(this,ra).x+r.x,y:Vr(this,ia).y-Vr(this,ra).y+r.y}),Gr(this,ra,r)),a}setOffset(e){const t=Vr(this,jr).getPlaneHelper().getPlaneOffsetFromOffset3D(e);Gr(this,ia,{x:t.x+Vr(this,aa).x+Vr(this,ra).x+Vr(this,oa).x+Vr(this,sa).x,y:t.y+Vr(this,aa).y+Vr(this,ra).y+Vr(this,oa).y+Vr(this,sa).y})}displayToPlaneIndex(e,t){const n=this.displayToPlanePos(e,t);return new i([Math.floor(n.x),Math.floor(n.y)])}displayToPlaneScale(e,t){return{x:e/Vr(this,ta).x,y:t/Vr(this,ta).y}}displayToPlanePos(e,t){const n=this.displayToPlaneScale(e,t);return{x:n.x+Vr(this,ia).x,y:n.y+Vr(this,ia).y}}planePosToDisplay(e,t){return{x:(e-Vr(this,ia).x+Vr(this,ra).x)*Vr(this,ta).x,y:(t-Vr(this,ia).y+Vr(this,ra).y)*Vr(this,ta).y}}displayToMainPlanePos(e,t){const n=this.displayToPlanePos(e,t);return{x:n.x-Vr(this,ra).x,y:n.y-Vr(this,ra).y}}display(e){Vr(this,Hr).style.display=e?"":"none"}isVisible(){return""===Vr(this,Hr).style.display}draw(){if(!Vr(this,Zr))return;let e={type:"renderstart",layerid:this.getId(),dataid:this.getDataIndex()};Vr(this,Sa).call(this,e),Vr(this,la)&&Wr(this,ga,wa).call(this),Vr(this,_r).globalAlpha=Vr(this,ea),this.clear(),Vr(this,_r).setTransform(Vr(this,ta).x,0,0,Vr(this,ta).y,-1*Vr(this,ia).x*Vr(this,ta).x,-1*Vr(this,ia).y*Vr(this,ta).y),Vr(this,_r).imageSmoothingEnabled=Vr(this,ha),Vr(this,_r).drawImage(Vr(this,Yr),0,0),e={type:"renderend",layerid:this.getId(),dataid:this.getDataIndex()},Vr(this,Sa).call(this,e)}initialise(e,t,n){Gr(this,$r,t),Gr(this,ea,Math.min(Math.max(n,0),1)),Gr(this,Xr,document.createElement("canvas")),Vr(this,Hr).appendChild(Vr(this,Xr)),Vr(this,Xr).getContext?(Gr(this,_r,Vr(this,Xr).getContext("2d")),Vr(this,_r)?(Gr(this,Yr,document.createElement("canvas")),Wr(this,da,Da).call(this,e),Gr(this,la,!0)):alert("Error: failed to get the 2D context.")):alert("Error: no canvas.getContext method.")}fitToContainer(e,t,n){let i=!1;if(Vr(this,Xr).width!==t.x||Vr(this,Xr).height!==t.y){if(!Ur(t.x,t.y))throw new Error("Cannot resize canvas "+t.x+", "+t.y);Vr(this,Xr).width=t.x,Vr(this,Xr).height=t.y,i=!0}const r=Vr(this,na),a=Vr(this,ta).x/Vr(this,na).x,o=Vr(this,ta).y/Vr(this,na).y,s={x:e*Vr(this,$r).x,y:e*Vr(this,$r).y},l={x:a*s.x,y:o*s.y};a===l.x&&o===l.y||(Gr(this,na,s),Gr(this,ta,l),i=!0);const c={x:n.x/s.x,y:n.y/s.y},u={x:Vr(this,sa).x*r.x/s.x,y:Vr(this,sa).y*r.y/s.y};Vr(this,aa).x===c.x&&Vr(this,aa).y===c.y&&Vr(this,sa).x===u.x&&Vr(this,sa).y===u.y||(Gr(this,sa,u),Gr(this,aa,c),Gr(this,ia,{x:Vr(this,aa).x+Vr(this,ra).x+Vr(this,oa).x+Vr(this,sa).x,y:Vr(this,aa).y+Vr(this,ra).y+Vr(this,oa).y+Vr(this,sa).y}),i=!0),i&&this.draw()}bindInteraction(){Vr(this,Hr).style.pointerEvents="auto";const e=Fr;for(let t=0;t<e.length;++t)Vr(this,Hr).addEventListener(e[t],Vr(this,Sa),{passive:!0})}unbindInteraction(){Vr(this,Hr).style.pointerEvents="none";const e=Fr;for(let t=0;t<e.length;++t)Vr(this,Hr).removeEventListener(e[t],Vr(this,Sa))}addEventListener(e,t){Vr(this,ua).add(e,t)}removeEventListener(e,t){Vr(this,ua).remove(e,t)}setCurrentPosition(e,t){return Vr(this,jr).setCurrentPosition(e)}clear(){Vr(this,_r).save(),Vr(this,_r).setTransform(1,0,0,1,0,0),Vr(this,_r).clearRect(0,0,Vr(this,Xr).width,Vr(this,Xr).height),Vr(this,_r).restore()}}function Da(e){if(!Ur(e.x,e.y))throw new Error("Cannot create canvas with size "+e.x+", "+e.y);Gr(this,Jr,e),Vr(this,Yr).width=Vr(this,Jr).x,Vr(this,Yr).height=Vr(this,Jr).y,Vr(this,_r).clearRect(0,0,Vr(this,Jr).x,Vr(this,Jr).y),Gr(this,Kr,Vr(this,_r).createImageData(Vr(this,Jr).x,Vr(this,Jr).y))}function wa(){Vr(this,jr).generateImageData(Vr(this,Kr)),Vr(this,Yr).getContext("2d").putImageData(Vr(this,Kr),0,0),Gr(this,la,!1)}var Ca=a(436),Ta=a.n(Ca);function Ia(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function La(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Pa(e,t,"set"),n),n}function ba(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Pa(e,t,"get"))}function Pa(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Aa=new WeakMap,Oa=new WeakMap,xa=new WeakMap,Fa=new WeakMap,Ra=new WeakMap,Ea=new WeakMap,Ma=new WeakMap,qa=new WeakMap,Ua=new WeakMap,Qa=new WeakMap;class ka{constructor(){Ia(this,Aa,{writable:!0,value:10}),Ia(this,Oa,{writable:!0,value:"Verdana"}),Ia(this,xa,{writable:!0,value:"#fff"}),Ia(this,Fa,{writable:!0,value:"#ffff80"}),Ia(this,Ra,{writable:!0,value:{x:1,y:1}}),Ia(this,Ea,{writable:!0,value:{x:1,y:1}}),Ia(this,Ma,{writable:!0,value:2}),Ia(this,qa,{writable:!0,value:{x:.25,y:.25}}),Ia(this,Ua,{writable:!0,value:.2}),Ia(this,Qa,{writable:!0,value:3})}getFontFamily(){return ba(this,Oa)}getFontSize(){return ba(this,Aa)}getStrokeWidth(){return ba(this,Ma)}getTextColour(){return ba(this,xa)}getLineColour(){return ba(this,Fa)}setLineColour(e){La(this,Fa,e)}setBaseScale(e){La(this,Ra,e)}setZoomScale(e){La(this,Ea,e)}getBaseScale(){return ba(this,Ra)}getZoomScale(){return ba(this,Ea)}scale(e){return e/ba(this,Ra).x}applyZoomScale(e){return{x:2*e/ba(this,Ea).x,y:2*e/ba(this,Ea).y}}getShadowOffset(){return ba(this,qa)}getTagOpacity(){return ba(this,Ua)}getTextPadding(){return ba(this,Qa)}getFontStr(){return"normal "+this.getFontSize()+"px sans-serif"}getLineHeight(){return this.getFontSize()+this.getFontSize()/5}getScaledFontSize(){return this.scale(this.getFontSize())}getScaledStrokeWidth(){return this.scale(this.getStrokeWidth())}getShadowLineColour(){return ae(this.getLineColour())}}function Ba(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Na(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Va(e,t,"get"))}function Wa(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Va(e,t,"set"),n),n}function Va(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function Ga(e){let t="shape";return e instanceof Ta().Line?t=4===e.points().length?"line":6===e.points().length?"protractor":"roi":e instanceof Ta().Rect?t="rectangle":e instanceof Ta().Ellipse&&(t="ellipse"),t}var za=new WeakMap,Ha=new WeakMap,ja=new WeakMap,Xa=new WeakMap,Ya=new WeakMap;class _a{constructor(e,t,n,i){Ba(this,za,{writable:!0,value:void 0}),Ba(this,Ha,{writable:!0,value:void 0}),Ba(this,ja,{writable:!0,value:void 0}),Ba(this,Xa,{writable:!0,value:void 0}),Ba(this,Ya,{writable:!0,value:void 0}),Wa(this,za,e),Wa(this,Ha,t),Wa(this,ja,n),Wa(this,Xa,void 0!==i&&i),Wa(this,Ya,e.getParent())}getName(){return"Draw-"+Na(this,Ha)}execute(){Na(this,Ya).add(Na(this,za)),Na(this,ja).draw(),Na(this,Xa)||this.onExecute({type:"drawcreate",id:Na(this,za).id()})}undo(){Na(this,za).remove(),Na(this,ja).draw(),this.onUndo({type:"drawdelete",id:Na(this,za).id()})}onExecute(e){}onUndo(e){}}var Za=new WeakMap,Ka=new WeakMap,Ja=new WeakMap,$a=new WeakMap;class eo{constructor(e,t,n,i){Ba(this,Za,{writable:!0,value:void 0}),Ba(this,Ka,{writable:!0,value:void 0}),Ba(this,Ja,{writable:!0,value:void 0}),Ba(this,$a,{writable:!0,value:void 0}),Wa(this,Za,e),Wa(this,Ka,t),Wa(this,Ja,n),Wa(this,$a,i)}getName(){return"Move-"+Na(this,Ka)}execute(){Na(this,Za).move(Na(this,Ja)),Na(this,$a).draw(),this.onExecute({type:"drawmove",id:Na(this,Za).id()})}undo(){const e={x:-Na(this,Ja).x,y:-Na(this,Ja).y};Na(this,Za).move(e),Na(this,$a).draw(),this.onUndo({type:"drawmove",id:Na(this,Za).id()})}onExecute(e){}onUndo(e){}}var to=new WeakMap,no=new WeakMap,io=new WeakMap,ro=new WeakMap,ao=new WeakMap,oo=new WeakMap,so=new WeakMap;class lo{constructor(e,t,n,i,r,a,o){Ba(this,to,{writable:!0,value:void 0}),Ba(this,no,{writable:!0,value:void 0}),Ba(this,io,{writable:!0,value:void 0}),Ba(this,ro,{writable:!0,value:void 0}),Ba(this,ao,{writable:!0,value:void 0}),Ba(this,oo,{writable:!0,value:void 0}),Ba(this,so,{writable:!0,value:void 0}),Wa(this,to,e),Wa(this,no,t),Wa(this,io,n),Wa(this,ro,i),Wa(this,ao,r),Wa(this,oo,a),Wa(this,so,o)}getName(){return"Change-"+Na(this,to)}execute(){Na(this,no).update(Na(this,ro),Na(this,so),Na(this,oo)),Na(this,ao).draw(),this.onExecute({type:"drawchange",id:Na(this,ro).getParent().id()})}undo(){Na(this,no).update(Na(this,io),Na(this,so),Na(this,oo)),Na(this,ao).draw(),this.onUndo({type:"drawchange",id:Na(this,io).getParent().id()})}onExecute(e){}onUndo(e){}}var co=new WeakMap,uo=new WeakMap,ho=new WeakMap,So=new WeakMap;class go{constructor(e,t,n){Ba(this,co,{writable:!0,value:void 0}),Ba(this,uo,{writable:!0,value:void 0}),Ba(this,ho,{writable:!0,value:void 0}),Ba(this,So,{writable:!0,value:void 0}),Wa(this,co,e),Wa(this,uo,t),Wa(this,ho,n),Wa(this,So,e.getParent())}getName(){return"Delete-"+Na(this,uo)}execute(){Na(this,co).remove(),Na(this,ho).draw(),this.onExecute({type:"drawdelete",id:Na(this,co).id()})}undo(){Na(this,So).add(Na(this,co)),Na(this,ho).draw(),this.onUndo({type:"drawcreate",id:Na(this,co).id()})}onExecute(e){}onUndo(e){}}function po(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function fo(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,yo(e,t,"get"))}function mo(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,yo(e,t,"set"),n),n}function yo(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function vo(e){return"shape"===e.name()}function Do(e){return e.name().startsWith("shape-")}function wo(e){return"label"===e.name()}function Co(e){return"position-group"===e.name()}function To(e){return function(t){return t.id()===e}}function Io(e){return"anchor"!==e.name()&&"label"!==e.name()}var Lo=new WeakMap,bo=new WeakMap;class Po{constructor(e){po(this,Lo,{writable:!0,value:void 0}),po(this,bo,{writable:!0,value:null}),mo(this,Lo,e)}getCurrentPosGroup(){const e=fo(this,Lo).getChildren((e=>e.id()===fo(this,bo)));let t=null;return 1===e.length?t=e[0]:0===e.length?(t=new(Ta().Group),t.name("position-group"),t.id(fo(this,bo)),t.visible(!0),fo(this,Lo).add(t)):re.warn("Unexpected number of draw position groups."),t}reset(){mo(this,Lo,null)}getGroup(e){const t=fo(this,Lo).findOne("#"+e);return void 0===t&&re.warn("Cannot find node with id: "+e),t}activateDrawLayer(e,t){const n=[t];for(let t=3;t<e.length();++t)n.push(t);mo(this,bo,e.toStringId(n));const i=fo(this,Lo).getChildren(Co);let r;for(let e=0,t=i.length;e<t;++e)r=!1,i[e].id()===fo(this,bo)&&(r=!0),i[e].visible(r);fo(this,Lo).draw()}getDrawDisplayDetails(){const e=[],t=fo(this,Lo).getChildren();for(let n=0,i=t.length;n<i;++n){const i=r(t[n].id()),a=t[n].getChildren();for(let t=0,n=a.length;t<n;++t){const n=a[t].getChildren(vo)[0],r=a[t].getChildren(wo)[0].getChildren()[0];let o=n.className;if("Line"===o){const e=a[t].getChildren(Do);if(n.closed())o="Roi";else if(0!==e.length){const t=e[0].name();o=-1!==t.indexOf("triangle")?"Arrow":-1!==t.indexOf("arc")?"Protractor":"Ruler"}}"Rect"===o&&(o="Rectangle"),e.push({id:a[t].id(),position:i.toString(),type:o,color:n.stroke(),meta:r.meta})}}return e}getDrawStoreDetails(){const e={},t=fo(this,Lo).getChildren(Co);let n,i;for(let r=0,a=t.length;r<a;++r){n=t[r].getChildren();for(let t=0,r=n.length;t<r;++t){i=n[t];const r=i.find(".anchor");for(let e=0;e<r.length;++e)r[e].remove();const a=i.find(".text");1!==a.length&&re.warn("There should not be more than one text per shape."),e[i.id()]={meta:a[0].meta}}}return e}setDrawings(e,t,n,i){const r=Ta().Node.create(e).getChildren(Co);for(let e=0,a=r.length;e<a;++e){const a=r[e];let o=fo(this,Lo).getChildren(To(a.id()))[0];void 0===o&&(o=new(Ta().Group)({id:a.id(),name:"position-group",visible:!1}),fo(this,Lo).add(o));const s=a.getChildren();for(let e=0,r=s.length;e<r;++e){const e=s[0];o.add(e);const r=e.getChildren(vo)[0],a=new _a(e,r.className,fo(this,Lo));if(a.onExecute=n,a.onUndo=n,t){const n=t[e.id()],i=e.getChildren(wo)[0].getText();i.meta=n.meta,i.setText(Ct(i.meta.textExpr,i.meta.quantification))}a.execute(),i(a)}}}updateDraw(e){const t=fo(this,Lo).findOne("#"+e.id);if(void 0===t)return void re.warn("[updateDraw] Cannot find group with id: "+e.id);const n=t.getChildren(vo);for(let t=0;t<n.length;++t)n[t].stroke(e.color);const i=t.getChildren(Do);for(let t=0;t<i.length;++t)void 0!==i[t].stroke()?i[t].stroke(e.color):void 0!==i[t].fill()&&i[t].fill(e.color);const r=t.getChildren(wo)[0],a=ae(e.color),o=r.getChildren();for(let t=0;t<o.length;++t)if(o[t].fill(e.color),"Text"===o[t].className){const n=o[t];n.shadowColor(a),void 0!==e.meta&&(n.meta=e.meta,n.setText(Ct(n.meta.textExpr,n.meta.quantification)),r.setVisible(0!==n.meta.textExpr.length))}fo(this,Lo).draw()}deleteDrawGroup(e,t,n){const i=Ga(e.getChildren(vo)[0]),r=new go(e,i,fo(this,Lo));r.onExecute=t,r.onUndo=t,r.execute(),n(r)}deleteDraw(e,t,n){const i=this.getGroup(e);return void 0!==i&&(this.deleteDrawGroup(i,t,n),!0)}deleteDraws(e,t){const n=fo(this,Lo).getChildren();for(;n.length;)this.deleteDrawGroup(n[0],e,t)}}function Ao(e,t,n){Oo(e,t),t.set(e,n)}function Oo(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function xo(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Ro(e,t,"get"))}function Fo(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Ro(e,t,"set"),n),n}function Ro(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Eo=new WeakMap,Mo=new WeakMap,qo=new WeakMap,Uo=new WeakMap,Qo=new WeakMap,ko=new WeakMap,Bo=new WeakMap,No=new WeakMap,Wo=new WeakMap,Vo=new WeakMap,Go=new WeakMap,zo=new WeakMap,Ho=new WeakMap,jo=new WeakMap,Xo=new WeakSet;class Yo{constructor(e){var t;Oo(this,t=Xo),t.add(this),Ao(this,Eo,{writable:!0,value:void 0}),Ao(this,Mo,{writable:!0,value:null}),Ao(this,qo,{writable:!0,value:void 0}),Ao(this,Uo,{writable:!0,value:void 0}),Ao(this,Qo,{writable:!0,value:{x:1,y:1}}),Ao(this,ko,{writable:!0,value:{x:0,y:0}}),Ao(this,Bo,{writable:!0,value:{x:0,y:0}}),Ao(this,No,{writable:!0,value:{x:0,y:0}}),Ao(this,Wo,{writable:!0,value:{x:0,y:0}}),Ao(this,Vo,{writable:!0,value:null}),Ao(this,Go,{writable:!0,value:void 0}),Ao(this,zo,{writable:!0,value:null}),Ao(this,Ho,{writable:!0,value:new wn}),Ao(this,jo,{writable:!0,value:e=>{e.srclayerid=this.getId(),e.dataid=xo(this,zo),xo(this,Ho).fireEvent(e)}}),Fo(this,Eo,e),xo(this,Eo).className+=" drawLayer"}getDataIndex(){return xo(this,zo)}getKonvaStage(){return xo(this,Mo)}getKonvaLayer(){return xo(this,Mo).getLayers()[0]}getDrawController(){return xo(this,Vo)}setPlaneHelper(e){Fo(this,Go,e)}getId(){return xo(this,Eo).id}getBaseSize(){return xo(this,qo)}getOpacity(){return xo(this,Mo).opacity()}setOpacity(e){xo(this,Mo).opacity(Math.min(Math.max(e,0),1))}addFlipOffsetX(){const e=xo(this,Mo).scale(),t=xo(this,Mo).size();xo(this,Wo).x+=t.width/e.x;const n=xo(this,Mo).offset();n.x+=xo(this,Wo).x,xo(this,Mo).offset(n)}addFlipOffsetY(){const e=xo(this,Mo).scale(),t=xo(this,Mo).size();xo(this,Wo).y+=t.height/e.y;const n=xo(this,Mo).offset();n.y+=xo(this,Wo).y,xo(this,Mo).offset(n)}setScale(e,t){const n=xo(this,Go).getTargetOrientedPositiveXYZ(e),i={x:xo(this,Qo).x*n.x,y:xo(this,Qo).y*n.y},r=xo(this,Mo).offset();if(1===Math.abs(e.x)&&1===Math.abs(e.y)&&1===Math.abs(e.z)){const e={x:r.x-xo(this,No).x,y:r.y-xo(this,No).y};Fo(this,No,{x:0,y:0}),xo(this,Mo).offset(e)}else if(void 0!==t){let e=xo(this,Go).getPlaneOffsetFromOffset3D({x:t.getX(),y:t.getY(),z:t.getZ()});e={x:e.x+xo(this,ko).x,y:e.y+xo(this,ko).y};const n=rs(r,xo(this,Mo).scale(),i,e),a={x:xo(this,No).x+n.x-r.x,y:xo(this,No).y+n.y-r.y};Fo(this,No,a),xo(this,Mo).offset(n)}xo(this,Mo).scale(i),function(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}(this,Xo,_o).call(this,i)}setOffset(e){const t=xo(this,Go).getPlaneOffsetFromOffset3D(e);xo(this,Mo).offset({x:t.x+xo(this,Bo).x+xo(this,ko).x+xo(this,No).x+xo(this,Wo).x,y:t.y+xo(this,Bo).y+xo(this,ko).y+xo(this,No).y+xo(this,Wo).y})}setBaseOffset(e,t){const n=xo(this,Go).getNativeScrollIndex(),i=xo(this,Go).getPlaneOffsetFromOffset3D({x:0===n?e.getX():t.getX(),y:1===n?e.getY():t.getY(),z:2===n?e.getZ():t.getZ()}),r=xo(this,ko).x!==i.x||xo(this,ko).y!==i.y;if(r){const e=xo(this,Mo).offset();xo(this,Mo).offset({x:e.x-xo(this,ko).x+i.x,y:e.y-xo(this,ko).y+i.y}),Fo(this,ko,i)}return r}display(e){xo(this,Eo).style.display=e?"":"none"}isVisible(){return""===xo(this,Eo).style.display}draw(){xo(this,Mo).draw()}initialise(e,t,n){Fo(this,qo,e),Fo(this,Uo,t),Fo(this,zo,n),Fo(this,Mo,new(Ta().Stage)({container:xo(this,Eo),width:xo(this,qo).x,height:xo(this,qo).y,listening:!1})),xo(this,Mo).getContent().setAttribute("style","");const i=new(Ta().Layer)({listening:!1,visible:!0});xo(this,Mo).add(i),Fo(this,Vo,new Po(i))}fitToContainer(e,t,n){xo(this,Mo).width(t.x),xo(this,Mo).height(t.y);const i=xo(this,Mo).scale().x/xo(this,Qo).x,r=xo(this,Mo).scale().y/xo(this,Qo).y;Fo(this,Qo,{x:e*xo(this,Uo).x,y:e*xo(this,Uo).y}),xo(this,Mo).scale({x:i*xo(this,Qo).x,y:r*xo(this,Qo).y}),Fo(this,Bo,{x:n.x/xo(this,Qo).x,y:n.y/xo(this,Qo).y}),xo(this,Mo).offset({x:xo(this,Bo).x+xo(this,ko).x+xo(this,No).x+xo(this,Wo).x,y:xo(this,Bo).y+xo(this,ko).y+xo(this,No).y+xo(this,Wo).y})}isGroupVisible(e){const t=xo(this,Vo).getGroup(e);return void 0!==t&&t.isVisible()}toogleGroupVisibility(e){const t=xo(this,Vo).getGroup(e);return void 0!==t&&(t.visible(!t.isVisible()),this.draw(),!0)}deleteDraw(e,t){xo(this,Vo).deleteDraw(e,xo(this,jo),t)}deleteDraws(e){xo(this,Vo).deleteDraws(xo(this,jo),e)}bindInteraction(){xo(this,Mo).listening(!0),xo(this,Eo).style.pointerEvents="auto";const e=Fr;for(let t=0;t<e.length;++t)xo(this,Eo).addEventListener(e[t],xo(this,jo))}unbindInteraction(){xo(this,Mo).listening(!1),xo(this,Eo).style.pointerEvents="none";const e=Fr;for(let t=0;t<e.length;++t)xo(this,Eo).removeEventListener(e[t],xo(this,jo))}setCurrentPosition(e,t){return this.getDrawController().activateDrawLayer(t,xo(this,Go).getScrollIndex()),!0}addEventListener(e,t){xo(this,Ho).add(e,t)}removeEventListener(e,t){xo(this,Ho).remove(e,t)}}function _o(e){const t=2/e.x,n=2/e.y,i=xo(this,Mo).find("Label");for(let e=0;e<i.length;++e)i[e].scale({x:t,y:n})}function Zo(e,t){Jo(e,t),t.add(e)}function Ko(e,t,n){Jo(e,t),t.set(e,n)}function Jo(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function $o(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function es(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,ns(e,t,"get"))}function ts(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,ns(e,t,"set"),n),n}function ns(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function is(e){let t=null;const n=e.target.closest(".layer");return n&&void 0!==n.id&&(t=function(e){const t=e.split("-layer-");return 2!==t.length&&re.warn("Not the expected layer div id format..."),{groupDivId:t[0],layerId:t[1]}}(n.id)),t}function rs(e,t,n,i){const r=(i.x-e.x)*t.x,a=(i.y-e.y)*t.y;return{x:i.x-r/n.x,y:i.y-a/n.y}}var as=new WeakMap,os=new WeakMap,ss=new WeakMap,ls=new WeakMap,cs=new WeakMap,us=new WeakMap,hs=new WeakMap,ds=new WeakMap,Ss=new WeakMap,gs=new WeakMap,ps=new WeakMap,fs=new WeakMap,ms=new WeakSet,ys=new WeakSet,vs=new WeakSet,Ds=new WeakSet,ws=new WeakSet,Cs=new WeakMap;class Ts{constructor(e){var t,n,r;Zo(this,ws),Zo(this,Ds),Zo(this,vs),Zo(this,ys),Zo(this,ms),Ko(this,as,{writable:!0,value:void 0}),Ko(this,os,{writable:!0,value:[]}),Ko(this,ss,{writable:!0,value:{x:1,y:1,z:1}}),Ko(this,ls,{writable:!0,value:{x:1,y:1,z:1}}),Ko(this,cs,{writable:!0,value:{x:0,y:0,z:0}}),Ko(this,us,{writable:!0,value:null}),Ko(this,hs,{writable:!0,value:null}),Ko(this,ds,{writable:!0,value:new wn}),Ko(this,Ss,{writable:!0,value:void 0}),Ko(this,gs,{writable:!0,value:!1}),Ko(this,ps,{writable:!0,value:void 0}),Ko(this,fs,{writable:!0,value:e=>{$o(this,Ds,Ps).call(this)}}),t=this,r=e=>{for(let e=0;e<es(this,os).length;++e)es(this,os)[e]instanceof va&&(es(this,os)[e].removeEventListener("positionchange",this.updateLayersToPositionChange),es(this,os)[e].removeEventListener("positionchange",es(this,Cs)));const t=new i(e.value[0]),n=new Ne(e.value[1]);ts(this,ps,n),es(this,gs)&&$o(this,Ds,Ps).call(this,n);let r=null,a=null;for(let i=0;i<es(this,os).length;++i){let o=!1;if(es(this,os)[i]instanceof va){const e=es(this,os)[i].getViewController(),t=e.getOrigin(),s=e.getOrigin(n);if(a){if(e.canSetPosition(n)&&void 0!==s){const e=r.minus(t),n=new pe(e.getX(),e.getY(),e.getZ()),l=a.minus(s),c=new pe(l.getX(),l.getY(),l.getZ());o=es(this,os)[i].setBaseOffset(n,c)}}else r=t,a=s}let s=!1;es(this,os)[i].getId()!==e.srclayerid&&(s=es(this,os)[i].setCurrentPosition(n,t)),!s&&o&&es(this,os)[i].draw()}for(let e=0;e<es(this,os).length;++e)es(this,os)[e]instanceof va&&(es(this,os)[e].addEventListener("positionchange",this.updateLayersToPositionChange),es(this,os)[e].addEventListener("positionchange",es(this,Cs)))},(n=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(n="updateLayersToPositionChange"))in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,Ko(this,Cs,{writable:!0,value:e=>{es(this,ds).fireEvent(e)}}),ts(this,as,e)}getTargetOrientation(){return es(this,Ss)}setTargetOrientation(e){ts(this,Ss,e)}getShowCrosshair(){return es(this,gs)}setShowCrosshair(e){ts(this,gs,e),e?(this.addEventListener("offsetchange",es(this,fs)),this.addEventListener("zoomchange",es(this,fs)),$o(this,Ds,Ps).call(this)):(this.removeEventListener("offsetchange",es(this,fs)),this.removeEventListener("zoomchange",es(this,fs)),$o(this,ws,As).call(this))}getDivId(){return es(this,as).id}getScale(){return es(this,ss)}getBaseScale(){return es(this,ls)}getAddedScale(){return{x:es(this,ss).x/es(this,ls).x,y:es(this,ss).y/es(this,ls).y,z:es(this,ss).z/es(this,ls).z}}getOffset(){return es(this,cs)}getNumberOfLayers(){return es(this,os).length}getActiveViewLayer(){return es(this,os)[es(this,us)]}getViewLayersByDataIndex(e){const t=[];for(let n=0;n<es(this,os).length;++n)es(this,os)[n]instanceof va&&es(this,os)[n].getDataIndex()===e&&t.push(es(this,os)[n]);return t}searchViewLayers(e){const t=[];for(let n=0;n<es(this,os).length;++n)es(this,os)[n]instanceof va&&es(this,os)[n].getViewController().equalImageMeta(e)&&t.push(es(this,os)[n]);return t}getViewDataIndices(){const e=[];for(let t=0;t<es(this,os).length;++t)es(this,os)[t]instanceof va&&e.push(es(this,os)[t].getDataIndex());return e}getActiveDrawLayer(){return es(this,os)[es(this,hs)]}getDrawLayersByDataIndex(e){const t=[];for(let n=0;n<es(this,os).length;++n)es(this,os)[n]instanceof Yo&&es(this,os)[n].getDataIndex()===e&&t.push(es(this,os)[n]);return t}setActiveViewLayer(e){ts(this,us,e)}setActiveViewLayerByDataIndex(e){for(let t=0;t<es(this,os).length;++t)if(es(this,os)[t]instanceof va&&es(this,os)[t].getDataIndex()===e){this.setActiveViewLayer(t);break}}setActiveDrawLayer(e){ts(this,hs,e)}setActiveDrawLayerByDataIndex(e){for(let t=0;t<es(this,os).length;++t)if(es(this,os)[t]instanceof Yo&&es(this,os)[t].getDataIndex()===e){this.setActiveDrawLayer(t);break}}addViewLayer(){const e=es(this,os).length,t=$o(this,vs,bs).call(this);es(this,as).append(t);const n=new va(t);return es(this,os).push(n),this.setActiveViewLayer(e),$o(this,ms,Is).call(this,n),n}addDrawLayer(){ts(this,hs,es(this,os).length);const e=$o(this,vs,bs).call(this);es(this,as).append(e);const t=new Yo(e);return es(this,os).push(t),$o(this,ys,Ls).call(this,t),t}empty(){ts(this,os,[]),ts(this,us,null),ts(this,hs,null);const e=es(this,as).getElementsByClassName("layer");if(e)for(;e.length>0;)e[0].remove()}calculateFitScale(){if(0===es(this,as).offsetWidth&&0===es(this,as).offsetHeight)throw new Error("Cannot fit to zero sized container.");const e=this.getMaxSize();if(void 0!==e)return Math.min(es(this,as).offsetWidth/e.x,es(this,as).offsetHeight/e.y)}setFitScale(e){const t=this.getMaxSize();if(void 0===t)return;const n={x:es(this,as).offsetWidth,y:es(this,as).offsetHeight},i={x:-.5*(n.x-Math.floor(t.x*e)),y:-.5*(n.y-Math.floor(t.y*e))};for(let t=0;t<es(this,os).length;++t)es(this,os)[t].fitToContainer(e,n,i);es(this,gs)&&$o(this,Ds,Ps).call(this)}getMaxSize(){let e={x:0,y:0};for(let t=0;t<es(this,os).length;++t)if(es(this,os)[t]instanceof va){const n=es(this,os)[t].getImageWorldSize();n.x>e.x&&(e.x=n.x),n.y>e.y&&(e.y=n.y)}return 0===e.x&&0===e.y&&(e=void 0),e}flipScaleZ(){es(this,ls).z*=-1,this.setScale(es(this,ls))}addScale(e,t){const n={x:es(this,ss).x*(1+e),y:es(this,ss).y*(1+e),z:es(this,ss).z*(1+e)};this.setScale(n,t)}setScale(e,t){ts(this,ss,e);for(let e=0;e<es(this,os).length;++e)es(this,os)[e].setScale(es(this,ss),t);const n=[e.x,e.y,e.z];void 0!==t&&(n.push(t.getX()),n.push(t.getY()),n.push(t.getZ())),es(this,Cs).call(this,{type:"zoomchange",value:n})}addTranslation(e){this.setOffset({x:es(this,cs).x-e.x,y:es(this,cs).y-e.y,z:es(this,cs).z-e.z})}setOffset(e){ts(this,cs,e);for(let e=0;e<es(this,os).length;++e)es(this,os)[e].setOffset(es(this,cs));es(this,Cs).call(this,{type:"offsetchange",value:[es(this,cs).x,es(this,cs).y,es(this,cs).z]})}reset(){this.setScale(es(this,ls)),this.setOffset({x:0,y:0,z:0})}draw(){for(let e=0;e<es(this,os).length;++e)es(this,os)[e].draw()}display(e){for(let t=0;t<es(this,os).length;++t)es(this,os)[t].display(e)}addEventListener(e,t){es(this,ds).add(e,t)}removeEventListener(e,t){es(this,ds).remove(e,t)}}function Is(e){e.addEventListener("positionchange",this.updateLayersToPositionChange);for(let t=0;t<Ri.length;++t)e.addEventListener(Ri[t],es(this,Cs));e.addEventListener("renderstart",es(this,Cs)),e.addEventListener("renderend",es(this,Cs))}function Ls(e){e.addEventListener("drawcreate",es(this,Cs)),e.addEventListener("drawdelete",es(this,Cs))}function bs(){const e=document.createElement("div");return e.id=this.getDivId()+"-layer-"+es(this,os).length,e.className="layer",e.style.pointerEvents="none",e}function Ps(e){void 0===e&&(e=es(this,ps)),$o(this,ws,As).call(this);const t=es(this,os)[0],n=t.getViewController().getPlanePositionFromPosition(e),i=t.planePosToDisplay(n.x,n.y),r=document.createElement("hr");r.id=this.getDivId()+"-scroll-crosshair-horizontal",r.className="horizontal",r.style.width=es(this,as).offsetWidth+"px",r.style.left="0px",r.style.top=i.y+"px";const a=document.createElement("hr");a.id=this.getDivId()+"-scroll-crosshair-vertical",a.className="vertical",a.style.width=es(this,as).offsetHeight+"px",a.style.left=i.x+"px",a.style.top="0px",es(this,as).appendChild(r),es(this,as).appendChild(a)}function As(){let e=document.getElementById(this.getDivId()+"-scroll-crosshair-horizontal");e&&e.remove(),e=document.getElementById(this.getDivId()+"-scroll-crosshair-vertical"),e&&e.remove()}function Os(e,t){Fs(e,t),t.add(e)}function xs(e,t,n){Fs(e,t),t.set(e,n)}function Fs(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Rs(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Es(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,qs(e,t,"set"),n),n}function Ms(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,qs(e,t,"get"))}function qs(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function Us(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const Qs={WindowLevelBinder:class{constructor(){Us(this,"getEventType",(function(){return"wlchange"})),Us(this,"getCallback",(function(e){return function(t){const n=e.getViewLayersByDataIndex(t.dataid);0!==n.length&&n[0].getViewController().setWindowLevel(t.value[0],t.value[1])}}))}},PositionBinder:class{constructor(){Us(this,"getEventType",(function(){return"positionchange"})),Us(this,"getCallback",(function(e){return function(t){const n=t.value[1],i=e.getActiveViewLayer().getViewController(),r=i.getCurrentPosition(),a=r.length(),o=n.length;o!==a&&(o===a-1?n.push(r.get(a-1)):o===a+1&&n.pop()),i.setCurrentPosition(new Ne(n))}}))}},ZoomBinder:class{constructor(){Us(this,"getEventType",(function(){return"zoomchange"})),Us(this,"getCallback",(function(e){return function(t){const n={x:t.value[0],y:t.value[1],z:t.value[2]};let i;6===t.value.length&&(i=new ke(t.value[3],t.value[4],t.value[5])),e.setScale(n,i),e.draw()}}))}},OffsetBinder:class{constructor(){Us(this,"getEventType",(function(){return"offsetchange"})),Us(this,"getCallback",(function(e){return function(t){e.setOffset({x:t.value[0],y:t.value[1],z:t.value[2]}),e.draw()}}))}},OpacityBinder:class{constructor(){Us(this,"getEventType",(function(){return"opacitychange"})),Us(this,"getCallback",(function(e){return function(t){if(void 0===t.dataid)return;const n=e.getViewLayersByDataIndex(t.dataid);0!==n.length&&(n[0].setOpacity(t.value),n[0].draw())}}))}}};var ks=new WeakMap,Bs=new WeakMap,Ns=new WeakMap,Ws=new WeakMap,Vs=new WeakSet,Gs=new WeakSet,zs=new WeakSet;class Hs{constructor(){Os(this,zs),Os(this,Gs),Os(this,Vs),xs(this,ks,{writable:!0,value:[]}),xs(this,Bs,{writable:!0,value:null}),xs(this,Ns,{writable:!0,value:[]}),xs(this,Ws,{writable:!0,value:null})}getLayerGroup(e){return Ms(this,ks)[e]}getNumberOfLayerGroups(){return Ms(this,ks).length}getActiveLayerGroup(){return this.getLayerGroup(Ms(this,Bs))}getViewLayersByDataIndex(e){let t=[];for(let n=0;n<Ms(this,ks).length;++n)t=t.concat(Ms(this,ks)[n].getViewLayersByDataIndex(e));return t}getDrawLayersByDataIndex(e){let t=[];for(let n=0;n<Ms(this,ks).length;++n)t=t.concat(Ms(this,ks)[n].getDrawLayersByDataIndex(e));return t}addLayerGroup(e){Es(this,Bs,Ms(this,ks).length);const t=new Ts(e),n=Ms(this,Ws)&&0!==Ms(this,Ws).length;return n&&this.unbindLayerGroups(),Ms(this,ks).push(t),n&&this.bindLayerGroups(),t}getLayerGroupByDivId(e){return Ms(this,ks).find((function(t){return t.getDivId()===e}))}setBinders(e){if(null==e)throw new Error("Cannot set null or undefined binders");0!==Ms(this,Ns).length&&this.unbindLayerGroups(),Es(this,Ns,e.slice()),this.bindLayerGroups()}empty(){this.unbindLayerGroups();for(let e=0;e<Ms(this,ks).length;++e)Ms(this,ks)[e].empty();Es(this,ks,[]),Es(this,Bs,null)}reset(){for(let e=0;e<Ms(this,ks).length;++e)Ms(this,ks)[e].reset()}draw(){for(let e=0;e<Ms(this,ks).length;++e)Ms(this,ks)[e].draw()}syncLayerGroupScale(){let e;const t=[];for(let n=0;n<Ms(this,ks).length;++n){const i=Ms(this,ks)[n].calculateFitScale();void 0!==i&&(t.push(n),(void 0===e||i<e)&&(e=i))}if(void 0!==e)for(let n=0;n<Ms(this,ks).length;++n)t.includes(n)&&Ms(this,ks)[n].setFitScale(e)}bindLayerGroups(){if(0!==Ms(this,ks).length&&1!==Ms(this,ks).length&&0!==Ms(this,Ns).length){Es(this,Ws,new Array(Ms(this,ks).length));for(let e=0;e<Ms(this,ks).length;++e)for(let t=0;t<Ms(this,Ns).length;++t)Rs(this,Gs,Xs).call(this,e,Ms(this,Ns)[t])}}unbindLayerGroups(){if(0!==Ms(this,ks).length&&1!==Ms(this,ks).length&&0!==Ms(this,Ns).length&&Ms(this,Ws)){for(let e=0;e<Ms(this,ks).length;++e)for(let t=0;t<Ms(this,Ns).length;++t)Rs(this,zs,Ys).call(this,e,Ms(this,Ns)[t]);Es(this,Ws,null)}}}function js(e,t){void 0===Ms(this,Ws)[t]&&(Ms(this,Ws)[t]=[]);let n=Ms(this,Ws)[t].find((function(t){return t.binder===e}));return void 0===n&&(n={binder:e,callback:n=>{Rs(this,zs,Ys).call(this,t,e),e.getCallback(Ms(this,ks)[t])(n),Rs(this,Gs,Xs).call(this,t,e)}},Ms(this,Ws)[t].push(n)),n.callback}function Xs(e,t){for(let n=0;n<Ms(this,ks).length;++n)n!==e&&Ms(this,ks)[e].addEventListener(t.getEventType(),Rs(this,Vs,js).call(this,t,n))}function Ys(e,t){for(let n=0;n<Ms(this,ks).length;++n)n!==e&&Ms(this,ks)[e].removeEventListener(t.getEventType(),Rs(this,Vs,js).call(this,t,n))}function _s(e,t){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.add(e)}function Zs(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}var Ks=new WeakSet,Js=new WeakSet,$s=new WeakSet,el=new WeakSet,tl=new WeakSet;class nl{constructor(){_s(this,tl),_s(this,el),_s(this,$s),_s(this,Js),_s(this,Ks)}toJSON(e){const t=e.getActiveLayerGroup(),n=t.getActiveViewLayer().getViewController(),i=n.getCurrentIndex(),r=t.getActiveDrawLayer(),a=r.getDrawController();return JSON.stringify({version:"0.5","window-center":n.getWindowLevel().center,"window-width":n.getWindowLevel().width,position:i.getValues(),scale:e.getAddedScale(),offset:e.getOffset(),drawings:r.getKonvaLayer().toObject(),drawingsDetails:a.getDrawStoreDetails()})}fromJSON(e){const t=JSON.parse(e);let n=null;if("0.1"===t.version)n=Zs(this,Ks,il).call(this,t);else if("0.2"===t.version)n=Zs(this,Js,rl).call(this,t);else if("0.3"===t.version)n=Zs(this,$s,al).call(this,t);else if("0.4"===t.version)n=Zs(this,el,ol).call(this,t);else{if("0.5"!==t.version)throw new Error("Unknown state file format version: '"+t.version+"'.");n=Zs(this,tl,sl).call(this,t)}return n}apply(e,t){const n=e.getActiveLayerGroup().getActiveViewLayer().getViewController();n.setWindowLevel(t["window-center"],t["window-width"]),n.setCurrentIndex(new i(t.position));const r=e.getActiveLayerGroup().getBaseScale();let a=null,o=null;if(void 0!==t.scaleCenter){a={x:t.scale*r.x,y:t.scale*r.y,z:1};const e=t.scaleCenter.x-t.scaleCenter.x*t.scale,n=t.scaleCenter.y-t.scaleCenter.y*t.scale,i=e+t.translation.x*a.x,s=n+t.translation.y*a.y;o={x:-i/a.x,y:-s/a.y,z:0}}else a={x:t.scale.x*r.x,y:t.scale.y*r.y,z:r.z},o={x:t.offset.x,y:t.offset.y,z:0};e.getActiveLayerGroup().setScale(a),e.getActiveLayerGroup().setOffset(o),e.render(0),e.setDrawings(t.drawings,t.drawingsDetails)}}function il(e){const t=function(e){const t=[],n={};let i,r;for(let a=0,o=e.length;a<o;++a){t[a]=[];for(let o=0,s=e[a].length;o<s;++o){i=e[a][o];const s=[];for(let e=0,t=i.length;e<t;++e){r=Ta().Node.create(i[e]),r.visible(!0);let t={x:0,y:0};const a=r.getChildren((function(e){return"shape"===e.name()}))[0];if(a.stroke(se(a.stroke())),"line-group"===r.name()){r.name("ruler-group");const e=new(Ta().Line)({points:[a.points()[0],a.points()[1],a.points()[0],a.points()[1]],name:"shape-tick0"});r.add(e);const t=new(Ta().Line)({points:[a.points()[2],a.points()[3],a.points()[2],a.points()[3]],name:"shape-tick1"});r.add(t)}const o=r.getChildren((function(e){return"arc"===e.name()}));1===o.length&&o[0].name("shape-arc");const l=r.getChildren((function(e){return"text"===e.name()}));let c=new(Ta().Text)({name:"text",text:""});1===l.length?(t.x=l[0].x(),t.y=l[0].y(),l[0].remove(),c=l[0]):0!==a.points().length&&(t={x:a.points()[0],y:a.points()[1]});const u=new(Ta().Label)({x:t.x,y:t.y,name:"label"});u.add(c),u.add(new(Ta().Tag)),r.add(u),s.push(JSON.stringify(r.toObject()));let h=c.text();const d=h.length;let S=null;"ruler-group"===r.name()?(S={length:{value:parseFloat(h.substring(0,d-2)),unit:h.substring(-2)}},h="{length}"):"ellipse-group"===r.name()||"rectangle-group"===r.name()?(S={surface:{value:parseFloat(h.substring(0,d-3)),unit:h.substring(-3)}},h="{surface}"):"protractor-group"!==r.name()&&"rectangle-group"!==r.name()||(S={angle:{value:parseFloat(h.substring(0,d-1)),unit:h.substring(-1)}},h="{angle}"),n[r.id()]={textExpr:h,longText:"",quant:S}}t[a].push(s)}}return{drawings:t,drawingsDetails:n}}(e.drawings);return e.drawings=ll(t.drawings).toObject(),e.drawingsDetails=cl(t.drawingsDetails),(e=ul(e)).drawings=hl(e.drawings),e}function rl(e){return e.drawings=ll(e.drawings).toObject(),e.drawingsDetails=cl(function(e){const t={},n="string"==typeof e?JSON.parse(e):e;for(let e=0,i=n.length;e<i;++e)for(let i=0,r=n[e].length;i<r;++i)for(let r=0,a=n[e][i].length;r<a;++r){const a=n[e][i][r];t[a.id]={textExpr:a.textExpr,longText:a.longText,quant:a.quant}}return t}(e.drawingsDetails)),(e=ul(e)).drawings=hl(e.drawings),e}function al(e){return e.drawingsDetails=cl(e.drawingsDetails),(e=ul(e)).drawings=hl(e.drawings),e}function ol(e){return(e=ul(e)).drawings=hl(e.drawings),e}function sl(e){return e}function ll(e){let t,n,r;const a=new(Ta().Layer)({listening:!1,visible:!0}),o="string"==typeof e?JSON.parse(e):e;for(let e=0,l=o.length;e<l;++e)for(let l=0,c=o[e].length;l<c;++l)if(n=o[e][l],0!==n.length){r=new(Ta().Group)({id:(s=new i([1,1,e,l]),"slice-"+s.get(2)+"_frame-"+(4===s.length()?s.get(3):0)),name:"position-group",visible:!1});for(let e=0,i=n.length;e<i;++e)t=Ta().Node.create(n[e]),t.draggable(!0),t.getChildren().forEach((function(e){e.draggable(!1)})),r.add(t);a.add(r)}var s;return a}function cl(e){const t={},n=Object.keys(e);for(let i=0,r=n.length;i<r;++i){const r=e[n[i]];t[n[i]]={meta:{textExpr:r.textExpr,longText:r.longText,quantification:r.quant}}}return t}function ul(e){const t=e.position;return e.position=[t.i,t.j,t.k],e}function hl(e){const t=e.children;for(let e=0,n=t.length;e<n;++e){const n=t[e],i=n.attrs.id.split("_"),r=parseInt(i[0].substring(6),10),a=parseInt(i[1].substring(6),10);let o="#2-";o+=0===r&&0!==a?a:r,n.attrs.id=o}return e}function dl(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Sl(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,pl(e,t,"set"),n),n}function gl(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,pl(e,t,"get"))}function pl(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var fl=new WeakMap,ml=new WeakMap,yl=new WeakMap,vl=new WeakMap;class Dl{constructor(){dl(this,fl,{writable:!0,value:[]}),dl(this,ml,{writable:!0,value:0}),dl(this,yl,{writable:!0,value:new wn}),dl(this,vl,{writable:!0,value:e=>{gl(this,yl).fireEvent(e)}})}getStackSize(){return gl(this,fl).length}getCurrentStackIndex(){return gl(this,ml)}add(e){var t;Sl(this,fl,gl(this,fl).slice(0,gl(this,ml))),gl(this,fl).push(e),Sl(this,ml,(t=gl(this,ml),++t)),gl(this,vl).call(this,{type:"undoadd",command:e.getName()})}undo(){var e;gl(this,ml)>0&&(Sl(this,ml,(e=gl(this,ml),--e)),gl(this,fl)[gl(this,ml)].undo(),gl(this,vl).call(this,{type:"undo",command:gl(this,fl)[gl(this,ml)].getName()}))}redo(){var e;gl(this,ml)<gl(this,fl).length&&(gl(this,fl)[gl(this,ml)].execute(),gl(this,vl).call(this,{type:"redo",command:gl(this,fl)[gl(this,ml)].getName()}),Sl(this,ml,(e=gl(this,ml),++e)))}addEventListener(e,t){gl(this,yl).add(e,t)}removeEventListener(e,t){gl(this,yl).remove(e,t)}}function wl(e,t){Tl(e,t),t.add(e)}function Cl(e,t,n){Tl(e,t),t.set(e,n)}function Tl(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Il(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Ll(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Pl(e,t,"get"))}function bl(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Pl(e,t,"set"),n),n}function Pl(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Al=new WeakMap,Ol=new WeakMap,xl=new WeakMap,Fl=new WeakMap,Rl=new WeakSet,El=new WeakSet;class Ml{constructor(e){wl(this,El),wl(this,Rl),Cl(this,Al,{writable:!0,value:void 0}),Cl(this,Ol,{writable:!0,value:null}),Cl(this,xl,{writable:!0,value:[]}),Cl(this,Fl,{writable:!0,value:{}}),bl(this,Al,e)}init(){for(const e in Ll(this,Al))Ll(this,Al)[e].init();window.addEventListener("keydown",Il(this,El,Ul).call(this,"window","keydown"),!0)}getToolList(){return Ll(this,Al)}hasTool(e){return void 0!==this.getToolList()[e]}getSelectedTool(){return Ll(this,Ol)}getSelectedToolEventHandler(e){return this.getSelectedTool()[e]}setSelectedTool(e){if(!this.hasTool(e))throw new Error("Unknown tool: '"+e+"'");Ll(this,Ol)&&Ll(this,Ol).activate(!1),bl(this,Ol,Ll(this,Al)[e]),Ll(this,Ol).activate(!0)}setToolFeatures(e){this.getSelectedTool()&&this.getSelectedTool().setFeatures(e)}bindLayer(e,t){void 0!==Ll(this,Fl)[t]&&Il(this,Rl,ql).call(this,Ll(this,Fl)[t]),e.bindInteraction();const n=Fr;for(let t=0;t<n.length;++t)e.addEventListener(n[t],Il(this,El,Ul).call(this,e.getId(),n[t]));Ll(this,Fl)[t]=e}}function ql(e){e.unbindInteraction();const t=Fr;for(let n=0;n<t.length;++n)e.removeEventListener(t[n],Il(this,El,Ul).call(this,e.getId(),t[n]))}function Ul(e,t){const n=e=>{if(Ll(this,Ol)){const t=Ll(this,Ol)[e.type];t&&t(e)}};if(void 0===Ll(this,xl)[e]&&(Ll(this,xl)[e]=[]),void 0===Ll(this,xl)[e][t]){let i=null;i="keydown"===t||"touchend"===t?function(e){n(e)}:function(e){!function(e){const t=qr(e);e._x=t[0].x,e._y=t[0].y,2===t.length&&(e._x1=t[1].x,e._y1=t[1].y)}(e),n(e)},Ll(this,xl)[e][t]=i}return Ll(this,xl)[e][t]}function Ql(e,t){Bl(e,t),t.add(e)}function kl(e,t,n){Bl(e,t),t.set(e,n)}function Bl(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Nl(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Wl(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Gl(e,t,"get"))}function Vl(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Gl(e,t,"set"),n),n}function Gl(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var zl=new WeakMap,Hl=new WeakMap,jl=new WeakMap,Xl=new WeakSet,Yl=new WeakSet;class _l{constructor(e){var t,n,i;Ql(this,Yl),Ql(this,Xl),kl(this,zl,{writable:!0,value:[]}),kl(this,Hl,{writable:!0,value:2}),kl(this,jl,{writable:!0,value:void 0}),t=this,i=e=>{if(!e.lengthComputable)return;if(void 0===e.subindex)return;if(void 0===e.index)return;const t=100*e.loaded/e.total;Wl(this,zl)[e.index][e.subindex]=t;let n=null;n=void 0!==e.item?e.item:{loaded:Nl(this,Xl,Zl).call(this,e.index),total:100,source:e.source},Wl(this,jl).call(this,{lengthComputable:!0,loaded:Nl(this,Yl,Kl).call(this),total:100,item:n})},(n=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(n="onprogress"))in t?Object.defineProperty(t,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[n]=i,Vl(this,jl,e)}setNumberOfDimensions(e){Vl(this,Hl,e)}setNToLoad(e){for(let t=0;t<e;++t){Wl(this,zl)[t]=[];for(let e=0;e<Wl(this,Hl);++e)Wl(this,zl)[t][e]=0}}getMonoProgressHandler(e,t){return n=>{n.index=e,n.subindex=t,this.onprogress(n)}}getUndefinedMonoProgressHandler(e){return t=>{t.subindex=e,this.onprogress(t)}}}function Zl(e){let t=0;for(let n=0;n<Wl(this,Hl);++n)t+=Wl(this,zl)[e][n];return t/Wl(this,Hl)}function Kl(){let e=0;const t=Wl(this,zl).length;for(let n=0;n<t;++n)e+=Nl(this,Xl,Zl).call(this,n);return Math.round(e/t)}function Jl(e){return new URL(e,window.location.origin)}function $l(e){const t={};let n=null;if(e&&-1!==(n=e.indexOf("?"))){t.base=e.substring(0,n);let i=e.indexOf("#");-1===i&&(i=e.length);const r=e.substring(n+1,i);t.query=function(e){const t={};if(e){const n=e.split("&");for(let e=0;e<n.length;++e){const i=n[e].split("=");t[i[0]]?(t[i[0]]instanceof Array||(t[i[0]]=[t[i[0]]]),t[i[0]].push(i[1])):t[i[0]]=i[1]}}return t}(r)}return t}function ec(e){const t=$l(e);return 0===Object.keys(t).length?null:t.query}function tc(e,t,n){const i=ec(e);i&&void 0!==i.input&&function(e,t,n){(function(e,t,n){e.type&&"manifest"===e.type?function(e,t){let n="";"/"===e.input[0]&&(n=window.location.protocol+"//"+window.location.host),n+=e.input;const i=new XMLHttpRequest;i.open("GET",decodeURIComponent(n),!0),i.responseType="document",i.onload=function(n){t(function(e,t){const n=[],i=e.getElementsByTagName("wado_query")[0].getAttribute("wadoURL")+"?requestType=WADO&contentType=application/dicom&",r=e.getElementsByTagName("Patient");r.length>1&&re.warn("More than one patient, loading first one.");const a=r[0].getElementsByTagName("Study");a.length>1&&re.warn("More than one study, loading first one.");const o=a[0].getAttribute("StudyInstanceUID"),s=a[0].getElementsByTagName("Series");s.length>1&&re.warn("More than one series, loading first one.");const l=s[0].getAttribute("SeriesInstanceUID"),c=s[0].getElementsByTagName("Instance");let u=c.length;t<u&&(u=t);for(let e=0;e<u;++e){const t=i+"&studyUID="+o+"&seriesUID="+l+"&objectUID="+c[e].getAttribute("SOPInstanceUID");n.push(t)}return n}(n.target.responseXML,e.nslices))},i.onerror=function(e){re.warn("RequestError while receiving manifest: "+e.target.status)},i.send(null)}(e,t):t(function(e,t){const n=[];let i="key";t&&(i=t);const r=decodeURIComponent(e),a=$l(r);if(0===Object.keys(a).length)n.push(r);else{const e=Object.keys(a.query);let t=null;for(let n=0;n<e.length;++n)if(a.query[e[n]]instanceof Array){t=e[n];break}if(t){const r=a.query[t];let o=a.base;""!==o&&"file"!==t&&(o+="?");let s,l=!1;for(let n=0;n<e.length;++n)e[n]!==t&&(l&&(o+="&"),o+=e[n]+"="+a.query[e[n]],l=!0);for(let e=0;e<r.length;++e)s=o,l&&(s+="&"),"key"===i&&(s+=t+"="),s+=r[e],n.push(s)}else n.push(r)}return n}(e.input,e.dwvReplaceMode),n)})(e,t.loadURLs,n),void 0!==e.state&&t.addEventListener("loadend",(function n(){t.removeEventListener("loadend",n),t.loadURLs([e.state])}))}(i,t,n)}function nc(e){const t=e["00280010"];if(void 0===t)throw new Error("Missing DICOM image number of rows");if(0===t.value.length)throw new Error("Empty DICOM image number of rows");const n=e["00280011"];if(void 0===n)throw new Error("Missing DICOM image number of columns");if(0===n.value.length)throw new Error("Empty DICOM image number of columns");return[n.value[0],t.value[0]]}class ic{getTime(e){}}function rc(e,t){oc(e,t),t.add(e)}function ac(e,t,n){oc(e,t),t.set(e,n)}function oc(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function sc(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function lc(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,uc(e,t,"set"),n),n}function cc(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,uc(e,t,"get"))}function uc(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}const hc={Text:0,ArrayBuffer:1};var dc=new WeakMap,Sc=new WeakMap,gc=new WeakMap,pc=new WeakMap,fc=new WeakMap,mc=new WeakMap,yc=new WeakMap,vc=new WeakSet,Dc=new WeakSet,wc=new WeakSet,Cc=new WeakSet,Tc=new WeakSet,Ic=new WeakMap,Lc=new WeakMap,bc=new WeakSet,Pc=new WeakSet,Ac=new WeakSet;class Oc{constructor(){rc(this,Ac),rc(this,Pc),rc(this,bc),rc(this,Tc),rc(this,Cc),rc(this,wc),rc(this,Dc),rc(this,vc),ac(this,dc,{writable:!0,value:null}),ac(this,Sc,{writable:!0,value:[]}),ac(this,gc,{writable:!0,value:null}),ac(this,pc,{writable:!0,value:0}),ac(this,fc,{writable:!0,value:0}),ac(this,mc,{writable:!0,value:void 0}),ac(this,yc,{writable:!0,value:void 0}),ac(this,Ic,{writable:!0,value:e=>{var t;lc(this,pc,(t=cc(this,pc),++t)),cc(this,pc)===cc(this,dc).length&&this.onload({source:cc(this,dc)})}}),ac(this,Lc,{writable:!0,value:e=>{var t;lc(this,fc,(t=cc(this,fc),++t)),cc(this,fc)===2*cc(this,dc).length&&this.onloadend({source:cc(this,dc)})}})}getDefaultCharacterSet(){return cc(this,yc)}setDefaultCharacterSet(e){lc(this,yc,e)}load(e,t){this.onloadstart({source:e}),1===e.length&&(Dt(e[0],"DICOMDIR")||Dt(e[0],".dcmdir"))?sc(this,Ac,Qc).call(this,e[0],t):sc(this,Pc,Uc).call(this,e,t)}abort(){lc(this,mc,!0);for(let e=0;e<cc(this,Sc).length;++e)4!==cc(this,Sc)[e].readyState&&cc(this,Sc)[e].abort();cc(this,gc)&&cc(this,gc).isLoading()&&cc(this,gc).abort()}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}}function xc(e){lc(this,dc,e),lc(this,pc,0),lc(this,fc,0),lc(this,mc,!1),sc(this,wc,Rc).call(this),sc(this,Tc,Mc).call(this)}function Fc(e){cc(this,Sc).push(e)}function Rc(){lc(this,Sc,[])}function Ec(e){lc(this,gc,e)}function Mc(){lc(this,gc,null)}function qc(e,t){return n=>{n.source=t,e(n)}}function Uc(e,t){if(void 0===e||0===e.length)return;sc(this,vc,xc).call(this,e);const n=new _l(this.onprogress);n.setNToLoad(e.length);const i=[];for(let e=0;e<Nh.length;++e)i.push(new Nh[e]);let r=e[0],a=null,o=!1;for(let s=0;s<i.length;++s)if(a=i[s],a.canLoadUrl(r,t)){o=!0,a.setOptions({numberOfFiles:e.length,defaultCharacterSet:this.getDefaultCharacterSet()}),a.onprogress=n.getUndefinedMonoProgressHandler(1),a.onloaditem=this.onloaditem,a.onload=cc(this,Ic),a.onloadend=cc(this,Lc),a.onerror=this.onerror,a.onabort=this.onabort,sc(this,Cc,Ec).call(this,a);break}if(!o)throw new Error("No loader found for url: "+r);const s=function(e,t,n){return i=>{const r=i.target.status;200!==r&&0!==r?(this.onerror({source:t,error:"GET "+i.target.responseURL+" "+i.target.status+" ("+i.target.statusText+")",target:i.target}),cc(this,Lc).call(this)):e.load(i.target.response,t,n)}};let l=0;const c=()=>{cc(this,Lc).call(this),l<cc(this,Sc).length-1&&!cc(this,mc)&&(++l,cc(this,Sc)[l].send(null))};for(let i=0;i<e.length;++i){if(r=e[i],!a.canLoadUrl(r,t))throw new Error("Input url of different type: "+r);const o=new XMLHttpRequest;if(o.open("GET",r,!0),void 0!==t){if(void 0!==t.requestHeaders){const e=t.requestHeaders;for(let t=0;t<e.length;++t)void 0!==e[t].name&&void 0!==e[t].value&&o.setRequestHeader(e[t].name,e[t].value)}void 0!==t.withCredentials&&(o.withCredentials=t.withCredentials)}o.onprogress=sc(this,bc,qc).call(this,n.getMonoProgressHandler(i,0),r),o.onload=s(a,r,i),o.onloadend=c,o.onerror=sc(this,bc,qc).call(this,this.onerror,r),o.onabort=sc(this,bc,qc).call(this,this.onabort,r),a.loadUrlAs()===hc.ArrayBuffer&&(o.responseType="arraybuffer"),sc(this,Dc,Fc).call(this,o)}let u=cc(this,Sc).length;void 0!==t&&void 0!==t.batchSize&&0!==u&&(u=Math.min(t.batchSize,cc(this,Sc).length));for(let e=0;e<u;++e)cc(this,mc)||(l=e,cc(this,Sc)[l].send(null))}function Qc(e,t){const n=new XMLHttpRequest;n.open("GET",e,!0),n.responseType="arraybuffer",n.onload=n=>{const i=n.target.status;if(200!==i&&0!==i)this.onerror({source:e,error:"GET "+n.target.responseURL+" "+n.target.status+" ("+n.target.statusText+")",target:n.target}),this.onloadend({});else{const i=function(e){const t=new un;t.parse(e);const n=t.getDicomElements();if(void 0===n["00041220"]||void 0===n["00041220"].value)return void re.warn("No Directory Record Sequence found in DICOMDIR.");const i=n["00041220"].value;if(0===i.length)return void re.warn("The Directory Record Sequence of the DICOMDIR is empty.");const r=[];let a=null,o=null;for(let e=0;e<i.length;++e){if(void 0===i[e]["00041430"]||void 0===i[e]["00041430"].value)continue;const t=i[e]["00041430"].value[0];if("STUDY"===t)o=[],r.push(o);else if("SERIES"===t)a=[],o.push(a);else if("IMAGE"===t){if(void 0===i[e]["00041500"]||void 0===i[e]["00041500"].value)continue;const t=i[e]["00041500"].value;a.push(t.join("/"))}}return r}(n.target.response)[0][0],r=e.split("/").slice(0,-1).join("/"),a=[];for(let e=0;e<i.length;++e)a.push(r+"/"+i[e]);sc(this,Pc,Uc).call(this,a,t)}},n.onerror=t=>{sc(this,bc,qc).call(this,this.onerror,e)(t),this.onloadend({})},n.onabort=t=>{sc(this,bc,qc).call(this,this.onabort,e)(t),this.onloadend({})},n.send(null)}class kc{checkElements(e){nc(e)}create(e,t,n){const i=nc(e),r=[i[0],i[1],1],a=e["00280008"];a&&r.push(a.value[0]);const o=new Ln(r),s=function(e){let t=1,n=1;const i=["00280030","00181164","00182010","00280034"];for(let r=0;r<i.length;++r){const a=e[i[r]];if(a&&2===a.value.length){t=parseFloat(a.value[0]),n=parseFloat(a.value[1]);break}}return 0===n&&(re.warn("Zero column spacing."),n=1),0===t&&(re.warn("Zero row spacing."),t=1),new On([n,t,1])}(e),l=e["00020010"].value[0],c=jt(l),u=zt(l),h=Ht(l),d=e["00200032"];let g=new Array(0,0,0);void 0!==d&&(g=[parseFloat(d.value[0]),parseFloat(d.value[1]),parseFloat(d.value[2])]);const p=e["00200037"];let f;if(void 0!==p){const e=new pe(parseFloat(p.value[0]),parseFloat(p.value[1]),parseFloat(p.value[2])),t=new pe(parseFloat(p.value[3]),parseFloat(p.value[4]),parseFloat(p.value[5])),n=e.crossProduct(t);f=new Ie([e.getX(),t.getX(),n.getX(),e.getY(),t.getY(),n.getY(),e.getZ(),t.getZ(),n.getZ()])}const m=new ke(g[0],g[1],g[2]),y=(new ic).getTime(e),v=new Gn(m,o,s,f,y);let D;const w=e["00080018"];void 0!==w&&(D=w.value[0]);let C=1;const T=e["00280002"];void 0!==T&&(C=T.value[0]);const I=o.getTotalSize()*C;if(I!==t.length){if(re.warn("Badly sized pixel buffer: "+t.length+" != "+I),!(I<t.length))throw new Error("Underestimated buffer size, can't fix it...");t=t.slice(0,o.getTotalSize())}const L=new Di(v,t,[D]),b=e["00280004"];if(void 0!==b){let e=b.value[0].toUpperCase();(c||u||h)&&"MONOCHROME1"!==e&&"MONOCHROME2"!==e&&(e="RGB"),"RGB"===e&&1===C&&(e="PALETTE COLOR"),L.setPhotometricInterpretation(e)}const P=e["00280006"];void 0!==P&&L.setPlanarConfiguration(P.value[0]);let A=1;const O=e["00281053"];if(void 0!==O){const e=parseFloat(O.value[0]);isNaN(e)||(A=e)}let x=0;const F=e["00281052"];if(void 0!==F){const e=parseFloat(F.value[0]);isNaN(e)||(x=e)}const R=new S(A,x);L.setRescaleSlopeAndIntercept(R);const E={numberOfFiles:n},M=e["00080060"];void 0!==M&&(E.Modality=M.value[0]);const q=e["00080016"];void 0!==q&&(E.SOPClassUID=q.value[0]);const U=e["0020000D"];void 0!==U&&(E.StudyInstanceUID=U.value[0]);const Q=e["0020000E"];void 0!==Q&&(E.SeriesInstanceUID=Q.value[0]);const k=e["00280101"];void 0!==k&&(E.BitsStored=k.value[0]);const B=e["00280103"];void 0!==B&&(E.PixelRepresentation=B.value[0]),E.IsSigned=1===E.PixelRepresentation;const W=function(e){let t;const n=["00281054","00541001"];for(let i=0;i<n.length;++i){const r=e[n[i]];void 0!==r&&(t=r.value[0])}return void 0!==t&&"CT"===e["00080060"].value[0]&&(t="HU"),t}(e);void 0!==W&&(E.pixelUnit=W);const V=e["00200052"];void 0!==V&&(E.FrameOfReferenceUID=V.value[0]);const G={},z=e["00281050"],H=e["00281051"],j=e["00281055"];if(void 0!==z&&void 0!==H){let e;for(let t=0;t<z.value.length;++t){const n=parseFloat(z.value[t]),i=parseFloat(H.value[t]);n&&i&&0!==i&&(e="",void 0!==j&&(e=j.value[t]),""===e&&(e="Default"+t),G[e]={wl:[new N(n,i)],name:e}),0===i&&re.warn("Zero window width found in DICOM.")}}if(E.windowPresets=G,"PALETTE COLOR"===L.getPhotometricInterpretation()){let t=e["00281201"],n=e["00281202"],i=e["00281203"];const r=e["00281101"];if(void 0!==r&&3===r.length)if(16===r[2]){let a=!1,o=r[0];0===o&&(o=65536);const s=t.vl;if(s!==2*o&&(a=!0,re.info("16bits lut but size is not double. desc: "+o+" vl: "+s)),8===parseInt(e["00280100"].value[0],10)&&(a=!0,re.info("Scaling 16bits color lut since bits allocated is 8.")),a){const e=function(e){return e>>8};t=t.map(e),n=n.map(e),i=i.map(e)}}else if(8===r[2]){re.info("Scaling 16bits color lut since the lut descriptor is 8.");let e=t.slice(0);t=new Uint8Array(e.buffer),e=n.slice(0),n=new Uint8Array(e.buffer),e=i.slice(0),i=new Uint8Array(e.buffer)}E.paletteLut={red:t,green:n,blue:i}}const X=e["00082144"];return void 0!==X&&(E.RecommendedDisplayFrameRate=parseInt(X.value[0],10)),L.setMeta(E),L}}function Bc(e,t){return JSON.stringify(e)===JSON.stringify(t)}function Nc(e,t){const n=e[t.tag];if(1===t.type||2===t.type){if(void 0===n)throw new Error("Missing or empty "+t.name)}else if(void 0===n)return;let i,r=!1;if(i=1===n.value.length?n.value[0]:n.value,Array.isArray(i))for(let e=0;e<t.enum.length;++e){if(!Array.isArray(t.enum[e]))throw new Error("Cannot compare array and non array tag value.");if(bt(t.enum[e],i)){r=!0;break}}else r=t.enum.includes(i);if(!r)throw new Error("Unsupported "+t.name+" value: "+i)}const Wc=[{name:"TransferSyntaxUID",tag:"x00020010",type:"1",enum:["1.2.840.10008.1.2.1"]},{name:"MediaStorageSOPClassUID",tag:"x00020002",type:"1",enum:["1.2.840.10008.5.1.4.1.1.66.4"]},{name:"SOPClassUID",tag:"x00020002",type:"1",enum:["1.2.840.10008.5.1.4.1.1.66.4"]},{name:"Modality",tag:"x00080060",type:"1",enum:["SEG"]},{name:"SegmentationType",tag:"x00620001",type:"1",enum:["BINARY"]},{name:"DimensionOrganizationType",tag:"x00209311",type:"3",enum:["3D"]},{name:"ImageType",tag:"x00080008",type:"1",enum:[["DERIVED","PRIMARY"]]},{name:"SamplesPerPixel",tag:"x00280002",type:"1",enum:[1]},{name:"PhotometricInterpretation",tag:"x00280004",type:"1",enum:["MONOCHROME2"]},{name:"PixelRepresentation",tag:"x00280103",type:"1",enum:[0]},{name:"BitsAllocated",tag:"x00280100",type:"1",enum:[1]},{name:"BitsStored",tag:"x00280101",type:"1",enum:[1]},{name:"HighBit",tag:"x00280102",type:"1",enum:[0]}];function Vc(e){const t={meaning:e["00080104"].value[0]};if(e["00080100"])t.value=e["00080100"].value[0];else if(e["00080119"])t.longValue=e["00080119"].value[0];else{if(!e["00080120"])throw Error("Invalid code with no value, no long value and no urn value.");t.urnValue=e["00080120"].value[0]}if(void 0!==t.value||void 0!==t.longValue){if(!e["00080102"])throw Error("No coding sheme designator when code value or long value is present");t.schemeDesignator=e["00080102"].value[0]}return t}function Gc(e){const t={number:e["00620004"].value[0],label:e["00620005"].value[0],algorithmType:e["00620008"].value[0]};if(e["00620009"]&&(t.algorithmName=e["00620009"].value[0]),void 0!==e["0062000C"])t.displayValue=e["006200C"].value;else if(void 0!==e["0062000D"]){const i=e["0062000D"].value,r=function(e){return function(e){function t(e){let t=null;return t=e<=.0031308?12.92*e:1.055*Math.pow(e,.416666667)-.055,Math.min(1,Math.max(0,t))}const n=e.x/100,i=e.y/100,r=e.z/100;return{r:Math.round(255*t(3.2406*n-1.5372*i-.4986*r)),g:Math.round(255*t(-.9689*n+1.8758*i+.0415*r)),b:Math.round(255*t(.0557*n-.204*i+1.057*r))}}(function(e){function t(e){let t=null;return t=e>.206896552?Math.pow(e,3):.128418549*e-.017712903,t}const n=oe,i=(e.l+16)/116;return{x:n.x*t(i+e.a/500),y:n.y*t(i),z:n.z*t(i-e.b/200)}}(e))}({l:.001525902*(n={l:i[0],a:i[1],b:i[2]}).l,a:.003891051*n.a-128,b:.003891051*n.b-128});t.displayValue=r}var n;if(void 0===e["00620003"])throw Error("Missing Segmented Property Category Code Sequence.");if(t.propertyCategoryCode=Vc(e["00620003"].value[0]),void 0===e["0062000F"])throw Error("Missing Segmented Property Type Code Sequence.");return t.propertyTypeCode=Vc(e["0062000F"].value[0]),void 0!==e["00620020"]&&(t.trackingId=e["00620020"].value[0],t.trackingUid=e["00620021"].value[0]),t}function zc(e){if(void 0===e["00280030"])return null;const t=e["00280030"],n=[parseFloat(t.value[0]),parseFloat(t.value[1])];return void 0!==e["00180050"]?n.push(parseFloat(e["00180050"].value[0])):void 0!==e["00180088"]&&n.push(parseFloat(e["00180088"].value[0])),new On(n)}function Hc(e){const t=[];if(void 0!==e["00089124"]){const n=e["00089124"].value;for(let e=0;e<n.length;++e){const i=[];if(void 0!==n[e]["00082112"]){const t=n[e]["00082112"].value;for(let e=0;e<t.length;++e){const n={};void 0!==t[e]["00081150"]&&(n.referencedSOPClassUID=t[e]["00081150"].value[0]),void 0!==t[e]["00081155"]&&(n.referencedSOPInstanceUID=t[e]["00081155"].value[0]),i.push(n)}}t.push(i)}}const n=e["00209111"].value[0]["00209157"].value,i=e["0062000A"].value[0]["0062000B"].value[0],r=e["00209113"].value[0]["00200032"].value;for(let e=0;e<r.length;++e)r[e]=parseFloat(r[e]);const a={dimIndex:n,imagePosPat:r,derivationImages:t,refSegmentNumber:i};if(void 0!==e["00209116"]){const t=e["00209116"];if(0!==t.value.length){const e=t.value[0]["00200037"].value;void 0!==e&&(a.imageOrientationPatient=e)}}if(void 0!==e["00289110"]){const t=e["00289110"];if(0!==t.value.length){const e=zc(t.value[0]);void 0!==e&&(a.spacing=e)}else re.warn("No shared functional group pixel measure sequence items.")}return a}class jc{create(e,t){for(let t=0;t<Wc.length;++t)Nc(e,Wc[t]);const n=nc(e),r=new Ln([n[0],n[1],1]),a=r.getTotalSize();let o=1;const s=e["00280008"];if(void 0!==s&&(o=parseInt(s.value[0],10)),o!==t.length/a)throw new Error("Buffer and numberOfFrames meta are not equal."+o+" "+t.length/a);const l=function(e){const t=e["00209221"];if(void 0===t||1!==t.value.length)throw new Error("Unsupported dimension organization sequence length");const n=t.value[0]["00209164"].value[0],i=[],r=e["00209222"];if(void 0!==r){const e=r.value;if(2!==e.length)throw new Error("Unsupported dimension index sequence length");let t;for(let r=0;r<e.length;++r){const a=e[r]["00209164"].value[0];if(a!==n)throw new Error("Dimension Index Sequence contains a unknown Dimension Organization");t=e[r]["00209165"].value[0];const o={DimensionOrganizationUID:a,DimensionIndexPointer:t};void 0!==e[r]["00209421"]&&(o.DimensionDescriptionLabel=e[r]["00209421"].value[0]),i.push(o)}if("(0020,0032)"!==t)throw new Error("Unsupported non image position as last index")}return{organizations:{value:[{DimensionOrganizationUID:n}]},indices:{value:i}}}(e),c=e["00620002"];if(void 0===c)throw new Error("Missing or empty segmentation sequence");const u=[];let h,d,S=!1;for(let e=0;e<c.value.length;++e){const t=Gc(c.value[e]);void 0!==t.displayValue.r&&void 0!==t.displayValue.g&&void 0!==t.displayValue.b&&(S=!0),u.push(t)}const g=e[52009229];if(void 0!==g){const e=g.value[0];if(void 0!==e["00209116"]){const t=e["00209116"];0!==t.value.length?d=t.value[0]["00200037"].value:re.warn("No shared functional group plane orientation sequence items.")}if(void 0!==e["00289110"]){const t=e["00289110"];0!==t.value.length?h=zc(t.value[0]):re.warn("No shared functional group pixel measure sequence items.")}}const p=function(e,t){return e.some((function(e){return Bc(t,e)}))},f=function(e,t){return e.findIndex((function(e){return Bc(t,e)}))},m=e[52009230];if(void 0===m)throw new Error("Missing or empty per frame functional sequence");if(o!==m.value.length)throw new Error("perFrameFuncGroupSequence meta and numberOfFrames are not equal.");const y=[];for(let e=0;e<m.value.length;++e)y.push(Hc(m.value[e]));const v=[];for(let e=0;e<y.length;++e){if(p(v,y[e].imagePosPat)||v.push(y[e].imagePosPat),void 0!==y[e].imageOrientationPatient)if(void 0===d)d=y[e].imageOrientationPatient;else if(!bt(d,y[e].imageOrientationPatient))throw new Error("Unsupported multi orientation dicom seg.");if(void 0!==y[e].spacing)if(void 0===h)h=y[e].spacing;else if(!h.equals(y[e].spacing))throw new Error("Unsupported multi resolution dicom seg.")}if(void 0===h)throw new Error("No spacing found for DICOM SEG");if(void 0===d)throw new Error("No imageOrientationPatient found for DICOM SEG");const D=new pe(parseFloat(d[0]),parseFloat(d[1]),parseFloat(d[2])),w=new pe(parseFloat(d[3]),parseFloat(d[4]),parseFloat(d[5])),C=D.crossProduct(w),T=new Ie([D.getX(),w.getX(),C.getX(),D.getY(),w.getY(),C.getY(),D.getZ(),w.getZ(),C.getZ()]);v.sort(function(e){const t=e.getInverse();return function(e,n){const i=t.multiplyArray3D(e),r=t.multiplyArray3D(n);return i[2]-r[2]}}(T));const I=function(e){return new ke(e[0],e[1],e[2])},L=[];for(let e=0;e<v.length;++e)L.push(I(v[e]));let b=h;const P=Xn(L,T,!1),A=h.getValues();void 0!==P&&P!==A[2]&&(A[2]=P,b=new On(A));const O=new Gn(L[0],r,b,T),x=function(e){let t=e>1e-4;return t&&(t=e>.001,t?(t=e>.01,t||re.warn("Using larger+ real world epsilon in SEG pos pat adding")):re.warn("Using larger real world epsilon in SEG pos pat adding")),t},F=[];F.push(v[0]);let R=0;for(let e=1;e<v.length;++e){++R;let t=new i([0,0,R]),n=O.indexToWorld(t).get3D();const r=L[e];let a=r.getDistance(n);const o=a;for(;x(a);)if(re.debug("Adding intermediate pos pats for DICOM seg at "+n.toString()),F.push([n.getX(),n.getY(),n.getZ()]),++R,t=new i([0,0,R]),n=O.indexToWorld(t).get3D(),a=r.getDistance(n),a>o)throw new Error("Test distance is increasing when adding intermediate pos pats");F.push(v[e])}const E=F.length,M=new Gn(L[0],r,b,T),q=[0];for(let e=1;e<E;++e)M.appendOrigin(I(F[e]),e),q.push(e);const U=function(e){return function(t){return t.number===e}},Q=S?3:1,k=new t.constructor(Q*a*E);k.fill(0);let B=null,N=null;for(let e=0;e<y.length;++e){R=f(F,y[e].imagePosPat),N=a*e,B=a*R;const n=u.find(U(y[e].refSegmentNumber)).displayValue;for(let e=0;e<a;++e)if(0!==t[N+e]){const t=Q*(B+e);S?(k[t]=n.r,k[t+1]=n.g,k[t+2]=n.b):k[t]=n}}const W=new Di(M,k,q);S&&W.setPhotometricInterpretation("RGB");const V=function(){const e={};for(let t=0;t<Wc.length;++t){const n=Wc[t];e[n.name]=n.enum[0]}return e}();V.StudyDate=e["00080020"].value[0],V.StudyTime=e["00080030"].value[0],V.StudyInstanceUID=e["0020000D"].value[0],V.StudyID=e["00200010"].value[0],V.SeriesInstanceUID=e["0020000E"].value[0],V.SeriesNumber=e["00200011"].value[0],V.ReferringPhysicianName=e["00080090"].value[0],V.PatientName=e["00100010"].value[0],V.PatientID=e["00100020"].value[0],V.PatientBirthDate=e["00100030"].value[0],V.PatientSex=e["00100040"].value[0],V.Manufacturer=e["00080070"].value[0],V.ManufacturerModelName=e["00081090"].value[0],V.DeviceSerialNumber=e["00181000"].value[0],V.SoftwareVersions=e["00181020"].value[0],V.DimensionOrganizationSequence=l.organizations,V.DimensionIndexSequence=l.indices,V.custom={segments:u,frameInfos:y,SOPInstanceUID:e["00080018"].value[0]},V.numberOfFiles=E;const G=e["00200052"];G&&(V.FrameOfReferenceUID=G.value[0]);const z=e["00282110"];return z&&(V.LossyImageCompression=z.value[0]),W.setMeta(V),W}}function Xc(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yc(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}var _c=new WeakSet;class Zc{constructor(e){var t,n;(function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")})(t=this,n=_c),n.add(t),Xc(this,"handleWorkerError",(e=>{Yc(this,_c,Kc).call(this),this.onerror({error:e}),this.onworkend({type:"work-end"})})),this.poolSize=e,this.taskQueue=[],this.freeThreads=[];for(let t=0;t<e;++t)this.freeThreads.push(new Jc(this));this.runningThreads=[]}addWorkerTask(e){if(this.freeThreads.length===this.poolSize&&this.onworkstart({type:"work-start"}),this.freeThreads.length>0){const t=this.freeThreads.shift();this.runningThreads.push(t),t.run(e)}else this.taskQueue.push(e)}abort(){Yc(this,_c,Kc).call(this),this.onabort({type:"work-abort"}),this.onworkend({type:"work-end"})}onTaskEnd(e){if(this.taskQueue.length>0){const t=this.taskQueue.shift();e.run(t)}else{e.stop(),this.freeThreads.push(e);for(let t=0;t<this.runningThreads.length;++t)this.runningThreads[t].getId()===e.getId()&&this.runningThreads.splice(t,1);this.freeThreads.length===this.poolSize&&(this.onwork({type:"work"}),this.onworkend({type:"work-end"}))}}onworkstart(e){}onworkitem(e){}onwork(e){}onworkend(e){}onerror(e){}onabort(e){}}function Kc(){this.taskQueue=[];for(let e=0;e<this.runningThreads.length;++e)this.runningThreads[e].stop();this.runningThreads=[]}class Jc{constructor(e){Xc(this,"onmessage",(e=>{e.itemNumber=this.runningTask.info.itemNumber,e.numberOfItems=this.runningTask.info.numberOfItems,e.dataIndex=this.runningTask.info.dataIndex,this.parentPool.onworkitem(e),this.parentPool.onTaskEnd(this)})),Xc(this,"onerror",(e=>{e.itemNumber=this.runningTask.info.itemNumber,e.numberOfItems=this.runningTask.info.numberOfItems,e.dataIndex=this.runningTask.info.dataIndex,this.parentPool.handleWorkerError(e),this.stop()})),this.parentPool=e,this.id=Math.random().toString(36).substring(2,15),this.runningTask=null,this.worker}getId(){return this.id}run(e){this.runningTask=e,void 0===this.worker&&(this.worker=new Worker(this.runningTask.script),this.worker.onmessage=this.onmessage,this.worker.onerror=this.onerror),this.worker.postMessage(this.runningTask.startMessage)}stop(){this.worker.terminate(),this.worker=void 0}}class $c{constructor(e,t,n){this.script=e,this.startMessage=t,this.info=n}}function eu(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function tu(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,iu(e,t,"get"))}function nu(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,iu(e,t,"set"),n),n}function iu(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}const ru="undefined"!=typeof JpegImage,au="undefined"!=typeof jpeg&&void 0!==jpeg.lossless,ou="undefined"!=typeof JpxImage,su={jpeg2000:"","jpeg-lossless":"","jpeg-baseline":"",rle:""};var lu=new WeakMap,cu=new WeakMap,uu=new WeakMap;class hu{constructor(e,t){eu(this,lu,{writable:!0,value:void 0}),eu(this,cu,{writable:!0,value:new Zc(10)}),eu(this,uu,{writable:!0,value:!1}),nu(this,lu,e)}decode(e,t,n){tu(this,uu)||(nu(this,uu,!0),tu(this,cu).onworkstart=this.ondecodestart,tu(this,cu).onworkitem=this.ondecodeditem,tu(this,cu).onwork=this.ondecoded,tu(this,cu).onworkend=this.ondecodeend,tu(this,cu).onerror=this.onerror,tu(this,cu).onabort=this.onabort);const i=new $c(tu(this,lu),{buffer:e,meta:t},n);tu(this,cu).addWorkerTask(i)}abort(){tu(this,cu).abort()}ondecodestart(e){}ondecodeditem(e){}ondecoded(e){}ondecodeend(e){}onerror(e){}onabort(e){}}var du=new WeakMap,Su=new WeakMap,gu=new WeakMap;class pu{constructor(e,t){eu(this,du,{writable:!0,value:void 0}),eu(this,Su,{writable:!0,value:void 0}),eu(this,gu,{writable:!0,value:0}),nu(this,du,e),nu(this,Su,t)}decode(e,t,n){var i;nu(this,gu,(i=tu(this,gu),++i));let r=null,a=null;if("jpeg-lossless"===tu(this,du)){if(!au)throw new Error("No JPEG Lossless decoder provided");const n=t.bitsAllocated/8,i=new Uint8Array(e);r=new jpeg.lossless.Decoder;const o=r.decode(i.buffer,0,i.buffer.byteLength,n);8===t.bitsAllocated?a=t.isSigned?new Int8Array(o.buffer):new Uint8Array(o.buffer):16===t.bitsAllocated&&(a=t.isSigned?new Int16Array(o.buffer):new Uint16Array(o.buffer))}else if("jpeg-baseline"===tu(this,du)){if(!ru)throw new Error("No JPEG Baseline decoder provided");r=new JpegImage,r.parse(e),a=r.getData(r.width,r.height)}else if("jpeg2000"===tu(this,du)){if(!ou)throw new Error("No JPEG 2000 decoder provided");r=new JpxImage,r.parse(e),a=r.tiles[0].items}else"rle"===tu(this,du)&&(r=new dwvdecoder.RleDecoder,a=r.decode(e,t.bitsAllocated,t.isSigned,t.sliceSize,t.samplesPerPixel,t.planarConfiguration));this.ondecodeditem({data:[a],dataIndex:n.dataIndex,numberOfItems:n.numberOfItems,itemNumber:n.itemNumber}),tu(this,gu)===tu(this,Su)&&(this.ondecoded({}),this.ondecodeend({}))}abort(){this.onabort({}),this.ondecodeend({})}ondecodestart(e){}ondecodeditem(e){}ondecoded(e){}ondecodeend(e){}onerror(e){}onabort(e){}}var fu=new WeakMap,mu=new WeakMap;class yu{constructor(e,t){eu(this,fu,{writable:!0,value:!1}),eu(this,mu,{writable:!0,value:null}),void 0!==su&&void 0!==su[e]?nu(this,mu,new hu(su[e],t)):nu(this,mu,new pu(e,t))}decode(e,t,n){tu(this,fu)||(nu(this,fu,!0),tu(this,mu).ondecodestart=this.ondecodestart,tu(this,mu).ondecodeditem=this.ondecodeditem,tu(this,mu).ondecoded=this.ondecoded,tu(this,mu).ondecodeend=this.ondecodeend,tu(this,mu).onerror=this.onerror,tu(this,mu).onabort=this.onabort),tu(this,mu).decode(e,t,n)}abort(){tu(this,mu).abort()}ondecodestart(e){}ondecodeditem(e){}ondecoded(e){}ondecodeend(e){}onerror(e){}onabort(e){}}function vu(e,t){wu(e,t),t.add(e)}function Du(e,t,n){wu(e,t),t.set(e,n)}function wu(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Cu(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Tu(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Lu(e,t,"get"))}function Iu(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Lu(e,t,"set"),n),n}function Lu(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var bu=new WeakMap,Pu=new WeakMap,Au=new WeakMap,Ou=new WeakMap,xu=new WeakMap,Fu=new WeakSet,Ru=new WeakSet;class Eu{constructor(){vu(this,Ru),vu(this,Fu),Du(this,bu,{writable:!0,value:void 0}),Du(this,Pu,{writable:!0,value:null}),Du(this,Au,{writable:!0,value:[]}),Du(this,Ou,{writable:!0,value:[]}),Du(this,xu,{writable:!0,value:[]})}setOptions(e){Iu(this,bu,e)}convert(e,t,n){this.onloadstart({source:t,dataIndex:n});const i=new un,r=new kc;void 0!==Tu(this,bu).defaultCharacterSet&&i.setDefaultCharacterSet(Tu(this,bu).defaultCharacterSet);try{i.parse(e),r.checkElements(i.getDicomElements())}catch(e){return this.onerror({error:e,source:t}),void this.onloadend({source:t})}const a=i.getDicomElements()["7FE00010"].value;i.getDicomElements()["7FE00010"].value=[];const o=function(e){let t=null;return jt(e)?t="jpeg2000":zt(e)?t="jpeg-baseline":Ht(e)?t="jpeg-lossless":Xt(e)&&(t="rle"),t}(i.getDicomElements()["00020010"].value[0]),s=null!==o;if(Tu(this,Au)[n]=i,Tu(this,Ou)[n]=a[0],s){const e={bitsAllocated:i.getDicomElements()["00280100"].value[0],isSigned:1===i.getDicomElements()["00280103"].value[0]},t=i.getDicomElements()["00280011"],r=i.getDicomElements()["00280010"];void 0!==t&&void 0!==r&&(e.sliceSize=t.value[0]*r.value[0]);const s=i.getDicomElements()["00280002"];void 0!==s&&(e.samplesPerPixel=s.value[0]);const l=i.getDicomElements()["00280006"];void 0!==l&&(e.planarConfiguration=l.value[0]);const c=a.length;null===Tu(this,Pu)&&(Iu(this,Pu,new yu(o,c)),Tu(this,Pu).ondecodeditem=e=>{Cu(this,Ru,qu).call(this,e),e.itemNumber+1===e.numberOfItems&&(this.onload(e),this.onloadend(e))},Tu(this,Pu).onerror=this.onerror,Tu(this,Pu).onabort=this.onabort);for(let t=0;t<c;++t)Tu(this,Pu).decode(a[t],e,{itemNumber:t,numberOfItems:c,dataIndex:n})}else this.onprogress({lengthComputable:!0,loaded:100,total:100,index:n,source:t}),Cu(this,Fu,Mu).call(this,n,t),this.onload({source:t}),this.onloadend({source:t})}abort(){Tu(this,Pu)&&Tu(this,Pu).abort()}onloadstart(e){}onloaditem(e){}onprogress(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}}function Mu(e,t){const n=Tu(this,Au)[e].getDicomElements();let i;const r=n["00080060"];void 0!==r&&"SEG"===r.value[0]&&(i=new jc),void 0===i&&(i=new kc);try{const r=i.create(n,Tu(this,Ou)[e],Tu(this,bu).numberOfFiles);this.onloaditem({data:{image:r,info:Tu(this,Au)[e].getDicomElements()},source:t})}catch(e){this.onerror({error:e,source:t}),this.onloadend({source:t})}}function qu(e){this.onprogress({lengthComputable:!0,loaded:e.itemNumber+1,total:e.numberOfItems,index:e.dataIndex,source:origin});const t=e.dataIndex,n=e.data[0];if(1!==e.numberOfItems){if(void 0===Tu(this,xu)[t]){Tu(this,xu)[t]=n.length;const i=e.numberOfItems*Tu(this,xu)[t];try{Tu(this,Ou)[t]=new n.constructor(i)}catch(e){if(e instanceof RangeError){const e=Math.floor(Math.log(i)/Math.log(2));re.error("Cannot allocate "+n.constructor.name+" of size: "+i+" (>2^"+e+") for decompressed data.")}return Tu(this,Pu).abort(),this.onerror({error:e,source:origin}),void this.onloadend({source:origin})}}n.length!==Tu(this,xu)[t]&&re.warn("Unsupported varying decompressed data size: "+n.length+" != "+Tu(this,xu)[t]),Tu(this,Ou)[t].set(n,Tu(this,xu)[t]*e.itemNumber)}else Tu(this,Ou)[t]=n;0===e.itemNumber&&Cu(this,Fu,Mu).call(this,t,origin)}function Uu(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Qu(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Bu(e,t,"get"))}function ku(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Bu(e,t,"set"),n),n}function Bu(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Nu=new WeakMap,Wu=new WeakMap,Vu=new WeakMap;function Gu(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,zu(e,t,"set"),n),n}function zu(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Hu=new WeakMap;function ju(e,t){Yu(e,t),t.add(e)}function Xu(e,t,n){Yu(e,t),t.set(e,n)}function Yu(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function _u(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Zu(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Ju(e,t,"set"),n),n}function Ku(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Ju(e,t,"get"))}function Ju(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var $u=new WeakMap,eh=new WeakMap,th=new WeakMap,nh=new WeakMap,ih=new WeakMap,rh=new WeakSet,ah=new WeakSet,oh=new WeakSet,sh=new WeakMap,lh=new WeakMap;class ch{constructor(){ju(this,oh),ju(this,ah),ju(this,rh),Xu(this,$u,{writable:!0,value:null}),Xu(this,eh,{writable:!0,value:null}),Xu(this,th,{writable:!0,value:0}),Xu(this,nh,{writable:!0,value:0}),Xu(this,ih,{writable:!0,value:void 0}),Xu(this,sh,{writable:!0,value:e=>{var t;Zu(this,th,(t=Ku(this,th),++t)),Ku(this,th)===Ku(this,$u).length&&this.onload({source:Ku(this,$u)})}}),Xu(this,lh,{writable:!0,value:e=>{var t;Zu(this,nh,(t=Ku(this,nh),++t)),Ku(this,nh)===Ku(this,$u).length&&this.onloadend({source:Ku(this,$u)})}})}getDefaultCharacterSet(){return Ku(this,ih)}setDefaultCharacterSet(e){Zu(this,ih,e)}load(e){if(void 0===e||0===e.length)return;_u(this,rh,uh).call(this,e),this.onloadstart({source:e});const t=new _l(this.onprogress);t.setNToLoad(e.length),t.setNumberOfDimensions(1);const n=[];for(let e=0;e<Nh.length;++e)n.push(new Nh[e]);let i=e[0],r=null,a=!1;for(let o=0;o<n.length;++o)if(r=n[o],r.canLoadMemory(i)){a=!0,r.setOptions({numberOfFiles:e.length,defaultCharacterSet:this.getDefaultCharacterSet()}),r.onprogress=t.getUndefinedMonoProgressHandler(0),r.onloaditem=this.onloaditem,r.onload=Ku(this,sh),r.onloadend=Ku(this,lh),r.onerror=this.onerror,r.onabort=this.onabort,_u(this,ah,hh).call(this,r);break}if(!a)throw new Error("No loader found for data: "+i.filename);for(let t=0;t<e.length;++t){if(i=e[t],!r.canLoadMemory(i))throw new Error("Input data of different type: "+i.filename);r.load(i.data,i.filename,t)}}abort(){Ku(this,eh)&&Ku(this,eh).isLoading()&&Ku(this,eh).abort()}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}}function uh(e){Zu(this,$u,e),Zu(this,th,0),Zu(this,nh,0),_u(this,oh,dh).call(this)}function hh(e){Zu(this,eh,e)}function dh(){Zu(this,eh,null)}function Sh(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,gh(e,t,"set"),n),n}function gh(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var ph=new WeakMap;function fh(e){const t=e.data.length,n=new Uint8Array(t/4*3);let i=0;for(let r=0;r<t;r+=4)n[i]=e.data[r],n[i+1]=e.data[r+1],n[i+2]=e.data[r+2],i+=3;return n}function mh(e,t,n,i,r,a){const o=new Ln([e,t,1]),s=new On([1,1,1]),l=new ke(0,0,n),c=new Gn(l,o,s),u=new Di(c,i,[a]);u.setPhotometricInterpretation("RGB");const h={BitsStored:8};return void 0!==r&&(h.numberOfFiles=r),u.setMeta(h),u}function yh(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function vh(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Dh(e,t,"set"),n),n}function Dh(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var wh=new WeakMap,Ch=new WeakSet;function Th(e,t){let n=t;n&&"jpg"!==n||(n="jpeg");const i=new Blob([e],{type:"image/"+n});return window.URL.createObjectURL(i)}var Ih=new WeakSet;function Lh(e,t){const n=new Uint8Array(e);let i="";for(let e=0;e<n.byteLength;++e)i+=String.fromCharCode(n[e]);return"data:video/"+t+";base64,"+window.btoa(i)}var bh=a(626),Ph=a.n(bh);function Ah(e,t,n){Oh(e,t),t.set(e,n)}function Oh(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function xh(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Fh(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Eh(e,t,"set"),n),n}function Rh(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Eh(e,t,"get"))}function Eh(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Mh=new WeakMap,qh=new WeakMap,Uh=new WeakMap,Qh=new WeakMap,kh=new WeakSet;function Bh(e,t,n){Rh(this,Uh).push({filename:Rh(this,qh),data:e});const i=100*Rh(this,Uh).length/Rh(this,Qh).length;if(this.onprogress({lengthComputable:!0,loaded:i/2,total:100,index:n,item:{loaded:i,total:100,source:t}}),Rh(this,Uh).length<Rh(this,Qh).length){const e=Rh(this,Uh).length;Fh(this,qh,Rh(this,Qh)[e].name),Rh(this,Qh)[e].async("arrayBuffer").then((e=>{xh(this,kh,Bh).call(this,e,t,n)}))}else{const e=new ch;e.onprogress=e=>{e.loaded=50+e.loaded/2,e.index=n,this.onprogress(e)},e.onloaditem=this.onloaditem,e.onload=this.onload,e.onloadend=e=>{Fh(this,Mh,!1),this.onloadend(e)},e.onerror=this.onerror,e.onabort=this.onabort,e.load(Rh(this,Uh))}}const Nh=[class{constructor(){Uu(this,Nu,{writable:!0,value:{}}),Uu(this,Wu,{writable:!0,value:!1}),Uu(this,Vu,{writable:!0,value:new Eu})}setOptions(e){ku(this,Nu,e)}isLoading(){return Qu(this,Wu)}load(e,t,n){Qu(this,Wu)||(Qu(this,Vu).setOptions(Qu(this,Nu)),Qu(this,Vu).onloadstart=this.onloadstart,Qu(this,Vu).onprogress=this.onprogress,Qu(this,Vu).onloaditem=this.onloaditem,Qu(this,Vu).onload=this.onload,Qu(this,Vu).onloadend=e=>{ku(this,Wu,!1),this.onloadend(e)},Qu(this,Vu).onerror=e=>{e.source=t,this.onerror(e)},Qu(this,Vu).onabort=this.onabort),ku(this,Wu,!0),Qu(this,Vu).convert(e,t,n)}abort(){ku(this,Wu,!1),Qu(this,Vu).abort()}canLoadFile(e){const t=Tt(e.name);return null===t||"dcm"===t}canLoadUrl(e,t){if(void 0!==t&&void 0!==t.requestHeaders){const e=function(e){return"Accept"===e.name&&vt(e.value,"application/dicom")&&"+"!==e.value[18]};return void 0!==t.requestHeaders.find(e)}const n=Jl(e),i=Tt(n.pathname),r=null===i,a="dcm"===i,o=n.searchParams.get("contentType");return null!=o?"application/dicom"===o:r||a}canLoadMemory(e){return void 0!==e["Content-Type"]&&"application/dicom"===e["Content-Type"]||void 0!==e.filename&&this.canLoadFile({name:e.filename})}loadFileAs(){return Yh.ArrayBuffer}loadUrlAs(){return hc.ArrayBuffer}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}},class{constructor(){var e,t,n;n={writable:!0,value:!1},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e=this,t=Hu),t.set(e,n)}setOptions(e){}isLoading(){return function(e,t){return t.get?t.get.call(e):t.value}(this,zu(this,Hu,"get"))}load(e,t,n){Gu(this,Hu,!0),this.onloadstart({source:t});try{this.onprogress({lengthComputable:!0,loaded:100,total:100,index:n,source:t});const i={data:e,source:t};this.onloaditem(i),this.onload(i)}catch(e){this.onerror({error:e,source:t})}finally{Gu(this,Hu,!1),this.onloadend({source:t})}}abort(){Gu(this,Hu,!1),this.onabort({}),this.onloadend({})}canLoadFile(e){return"json"===Tt(e.name)}canLoadUrl(e,t){if(void 0!==t&&void 0!==t.requestHeaders){const e=function(e){return"Accept"===e.name&&vt(e.value,"application/json")&&vt(e.value,"application/dicom+json")};return void 0!==t.requestHeaders.find(e)}return"json"===Tt(Jl(e).pathname)}canLoadMemory(e){return!(void 0===e["Content-Type"]||!e["Content-Type"].includes("json"))||void 0!==e.filename&&this.canLoadFile({name:e.filename})}loadFileAs(){return Yh.Text}loadUrlAs(){return hc.Text}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}},class{constructor(){var e,t,n;n={writable:!0,value:!1},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e=this,t=ph),t.set(e,n)}setOptions(e){}isLoading(){return function(e,t){return t.get?t.get.call(e):t.value}(this,gh(this,ph,"get"))}load(e,t,n){this.onloadstart({source:t}),Sh(this,ph,!0);const i=new ch;i.onprogress=e=>{e.loaded=50+e.loaded/2,e.index=n,this.onprogress(e)},i.onloaditem=this.onloaditem,i.onload=this.onload,i.onloadend=e=>{Sh(this,ph,!1),this.onloadend(e)},i.onerror=this.onerror,i.onabort=this.onabort,i.load(function(e){const t=new Uint8Array(e),n=[];if(0===t.length)return n;const i=xt(new Uint8Array([13,10,13,10]));let r=Ot(t,i,0);if(void 0===r)throw new Error("Can't find the end of the first multipart header");const a=At(t.slice(0,r)).split("\r\n");let o;for(let e=0;e<a.length;++e)if("-"===a[e][0]&&"-"===a[e][1]){o=a[e];break}if(void 0===o)throw new Error("Can't find the boundary between multi-parts");const s=xt(It(o)),l=o.length;let c=Ot(t,s,0);for(;void 0!==r;){const e={},a=At(t.slice(c+l,r)).split("\r\n");for(let t=0;t<a.length;++t){const n=a[t],i=n.indexOf(":");if(-1!==i){const t=n.substring(0,i).trim(),r=n.substring(i+1).trim();e[t]=r}}if(c=Ot(t,s,r),void 0===c)break;const o=r+4,u=c-2;e.data=o<u?t.slice(o,u).buffer:new Uint8Array,n.push(e),r=Ot(t,i,c+l)}return n}(e))}abort(){Sh(this,ph,!1),this.onabort({}),this.onloadend({})}canLoadFile(e){return!1}canLoadUrl(e,t){if(void 0!==t&&void 0!==t.requestHeaders){const e=function(e){return"Accept"===e.name&&vt(e.value,"multipart/related")};return void 0!==t.requestHeaders.find(e)}return!1}canLoadMemory(e){return!1}loadFileAs(){return Yh.ArrayBuffer}loadUrlAs(){return hc.ArrayBuffer}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}},class{constructor(){var e;yh(this,e=Ch),e.add(this),function(e,t,n){yh(e,t),t.set(e,{writable:!0,value:!1})}(this,wh)}setOptions(e){}isLoading(){return!0}load(e,t,n){vh(this,wh,!1);const i=new Image;if(i.onload=e=>{try{if(!function(e,t){return t.get?t.get.call(e):t.value}(this,Dh(this,wh,"get"))){this.onprogress({lengthComputable:!0,loaded:100,total:100,index:n,source:t});const i=function(e,t){const n=e.width,i=e.height,r=document.createElement("canvas");r.width=n,r.height=i;const a=r.getContext("2d");a.drawImage(e,0,0);const o=a.getImageData(0,0,n,i),s={};"string"==typeof e.origin?s.origin={value:e.origin}:(s.fileName={value:e.origin.name},s.fileType={value:e.origin.type},s.fileLastModifiedDate={value:e.origin.lastModifiedDate}),s.imageWidth={value:n},s.imageHeight={value:i};const l=e.index?e.index:0;return s.imageUid={value:l},{data:{image:mh(n,i,l,fh(o),1,l),info:s},source:t}}(e.target,t);this.onloaditem(i),this.onload(i)}}catch(e){this.onerror({error:e,source:t})}finally{this.onloadend({source:t})}},i.origin=t,i.index=n,"string"==typeof t){const n=t.split(".").pop().toLowerCase();i.src=function(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}(this,Ch,Th).call(this,e,n)}else i.src=e}abort(){vh(this,wh,!0),this.onabort({}),this.onloadend({})}canLoadFile(e){return void 0!==e.type&&e.type.match("image.*")}canLoadUrl(e,t){if(void 0!==t&&void 0!==t.requestHeaders){const e=function(e){return"Accept"===e.name&&vt(e.value,"image/")};return void 0!==t.requestHeaders.find(e)}const n=Jl(e),i=Tt(n.pathname),r="jpeg"===i||"jpg"===i||"png"===i||"gif"===i,a=n.searchParams.get("contentType");return null!=a?"image/jpeg"===a||"image/png"===a||"image/gif"===a:r}canLoadMemory(e){return void 0!==e.filename&&this.canLoadFile({name:e.filename})}loadFileAs(){return Yh.DataURL}loadUrlAs(){return hc.ArrayBuffer}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}},class{constructor(){var e,t;(function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")})(e=this,t=Ih),t.add(e)}setOptions(e){}isLoading(){return!0}load(e,t,n){const i=document.createElement("video");if("string"==typeof t){const n=t.split(".").pop().toLowerCase();i.src=function(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}(this,Ih,Lh).call(this,e,n)}else i.src=e;i.file=t,i.index=n,i.onloadedmetadata=e=>{try{!function(e,t,n,i,r,a,o){const s=e.videoWidth,l=e.videoHeight,c=Math.ceil(30*e.duration),u={};e.file&&(u.fileName={value:e.file.name},u.fileType={value:e.file.type},u.fileLastModifiedDate={value:e.file.lastModifiedDate}),u.imageWidth={value:s},u.imageHeight={value:l},u.numberOfFrames={value:c},u.imageUid={value:0};const h=document.createElement("canvas");h.width=s,h.height=l;const d=h.getContext("2d");e.addEventListener("seeked",(function h(f){(function(){i({lengthComputable:!0,loaded:S,total:c,index:a,source:o}),d.drawImage(e,0,0);const n=fh(d.getImageData(0,0,s,l));0===S?(g=mh(s,l,1,n,c,a),t({data:{image:g,info:u},source:o})):g.appendFrameBuffer(n,S),++S})(),p+=1/30,p<=f.target.duration?this.currentTime=p:(n({source:o}),r({source:o}),e.removeEventListener("seeked",h))}),!1);let S=0,g=null,p=0;e.currentTime=p}(e.target,this.onloaditem,this.onload,this.onprogress,this.onloadend,n,t)}catch(e){this.onerror({error:e,source:t}),this.onloadend({source:t})}}}abort(){this.onabort({}),this.onloadend({})}canLoadFile(e){return void 0!==e.type&&e.type.match("video.*")}canLoadUrl(e,t){if(void 0!==t&&void 0!==t.requestHeaders){const e=function(e){return"Accept"===e.name&&vt(e.value,"video/")};return void 0!==t.requestHeaders.find(e)}const n=Tt(Jl(e).pathname);return"mp4"===n||"ogg"===n||"webm"===n}canLoadMemory(e){return void 0!==e.filename&&this.canLoadFile({name:e.filename})}loadFileAs(){return Yh.DataURL}loadUrlAs(){return hc.ArrayBuffer}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}},class{constructor(){var e;Oh(this,e=kh),e.add(this),Ah(this,Mh,{writable:!0,value:!1}),Ah(this,qh,{writable:!0,value:""}),Ah(this,Uh,{writable:!0,value:[]}),Ah(this,Qh,{writable:!0,value:null})}setOptions(e){}isLoading(){return Rh(this,Mh)}load(e,t,n){this.onloadstart({source:t}),Fh(this,Mh,!0),Ph().loadAsync(e).then((e=>{Fh(this,Uh,[]),Fh(this,Qh,e.file(/.*\.dcm/));const i=Rh(this,Uh).length;Fh(this,qh,Rh(this,Qh)[i].name),Rh(this,Qh)[i].async("arrayBuffer").then((e=>{xh(this,kh,Bh).call(this,e,t,n)}))}))}abort(){Fh(this,Mh,!1),this.onabort({}),this.onloadend({})}canLoadFile(e){return"zip"===Tt(e.name)}canLoadUrl(e,t){if(void 0!==t&&void 0!==t.requestHeaders){const e=function(e){return"Accept"===e.name&&vt(e.value,"application/zip")};return void 0!==t.requestHeaders.find(e)}return"zip"===Tt(Jl(e).pathname)}canLoadMemory(e){return!(void 0===e["Content-Type"]||!e["Content-Type"].includes("zip"))||void 0!==e.filename&&this.canLoadFile({name:e.filename})}loadFileAs(){return Yh.ArrayBuffer}loadUrlAs(){return hc.ArrayBuffer}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}}];function Wh(e,t){Gh(e,t),t.add(e)}function Vh(e,t,n){Gh(e,t),t.set(e,n)}function Gh(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function zh(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Hh(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Xh(e,t,"set"),n),n}function jh(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Xh(e,t,"get"))}function Xh(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}const Yh={Text:0,ArrayBuffer:1,DataURL:2};var _h=new WeakMap,Zh=new WeakMap,Kh=new WeakMap,Jh=new WeakMap,$h=new WeakMap,ed=new WeakMap,td=new WeakSet,nd=new WeakSet,id=new WeakSet,rd=new WeakSet,ad=new WeakSet,od=new WeakMap,sd=new WeakMap,ld=new WeakSet;class cd{constructor(){Wh(this,ld),Wh(this,ad),Wh(this,rd),Wh(this,id),Wh(this,nd),Wh(this,td),Vh(this,_h,{writable:!0,value:null}),Vh(this,Zh,{writable:!0,value:[]}),Vh(this,Kh,{writable:!0,value:null}),Vh(this,Jh,{writable:!0,value:0}),Vh(this,$h,{writable:!0,value:0}),Vh(this,ed,{writable:!0,value:void 0}),Vh(this,od,{writable:!0,value:e=>{var t;Hh(this,Jh,(t=jh(this,Jh),++t)),jh(this,Jh)===jh(this,_h).length&&this.onload({source:jh(this,_h)})}}),Vh(this,sd,{writable:!0,value:e=>{var t;Hh(this,$h,(t=jh(this,$h),++t)),jh(this,$h)===2*jh(this,_h).length&&this.onloadend({source:jh(this,_h)})}})}getDefaultCharacterSet(){return jh(this,ed)}setDefaultCharacterSet(e){Hh(this,ed,e)}load(e){if(void 0===e||0===e.length)return;zh(this,td,ud).call(this,e),this.onloadstart({source:e});const t=new _l(this.onprogress);t.setNToLoad(e.length);const n=[];for(let e=0;e<Nh.length;++e)n.push(new Nh[e]);let i=e[0],r=null,a=!1;for(let o=0;o<n.length;++o)if(r=n[o],r.canLoadFile(i)){a=!0,r.setOptions({numberOfFiles:e.length,defaultCharacterSet:this.getDefaultCharacterSet()}),r.onprogress=t.getUndefinedMonoProgressHandler(1),r.onloaditem=this.onloaditem,r.onload=jh(this,od),r.onloadend=jh(this,sd),r.onerror=this.onerror,r.onabort=this.onabort,zh(this,rd,Sd).call(this,r);break}if(!a)throw new Error("No loader found for file: "+i.name);const o=function(e,t,n){return i=>{e.load(i.target.result,t,n)}};for(let n=0;n<e.length;++n){if(i=e[n],!r.canLoadFile(i))throw new Error("Input file of different type: "+i);const a=new FileReader;zh(this,nd,hd).call(this,a),a.onprogress=zh(this,ld,pd).call(this,t.getMonoProgressHandler(n,0),i),a.onload=o(r,i,n),a.onloadend=jh(this,sd),a.onerror=zh(this,ld,pd).call(this,this.onerror,i),a.onabort=zh(this,ld,pd).call(this,this.onabort,i),r.loadFileAs()===Yh.Text?a.readAsText(i):r.loadFileAs()===Yh.DataURL?a.readAsDataURL(i):r.loadFileAs()===Yh.ArrayBuffer&&a.readAsArrayBuffer(i)}}abort(){for(let e=0;e<jh(this,Zh).length;++e)1===jh(this,Zh)[e].readyState&&jh(this,Zh)[e].abort();jh(this,Kh)&&jh(this,Kh).isLoading()&&jh(this,Kh).abort()}onloadstart(e){}onprogress(e){}onloaditem(e){}onload(e){}onloadend(e){}onerror(e){}onabort(e){}}function ud(e){Hh(this,_h,e),Hh(this,Jh,0),Hh(this,$h,0),zh(this,id,dd).call(this),zh(this,ad,gd).call(this)}function hd(e){jh(this,Zh).push(e)}function dd(){Hh(this,Zh,[])}function Sd(e){Hh(this,Kh,e)}function gd(){Hh(this,Kh,null)}function pd(e,t){return n=>{n.source=t,e(n)}}function fd(e,t){yd(e,t),t.add(e)}function md(e,t,n){yd(e,t),t.set(e,n)}function yd(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function vd(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Dd(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Cd(e,t,"get"))}function wd(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Cd(e,t,"set"),n),n}function Cd(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Td=new WeakMap,Id=new WeakMap,Ld=new WeakMap,bd=new WeakSet,Pd=new WeakSet,Ad=new WeakSet,Od=new WeakSet,xd=new WeakSet,Fd=new WeakSet,Rd=new WeakSet;class Ed{constructor(e){fd(this,Rd),fd(this,Fd),fd(this,xd),fd(this,Od),fd(this,Ad),fd(this,Pd),fd(this,bd),md(this,Td,{writable:!0,value:void 0}),md(this,Id,{writable:!0,value:{}}),md(this,Ld,{writable:!0,value:-1}),wd(this,Td,e)}loadFiles(e){"json"===e[0].name.split(".").pop().toLowerCase()?vd(this,Od,Qd).call(this,e[0]):vd(this,Pd,qd).call(this,e)}loadURLs(e,t){"json"===e[0].split(".").pop().toLowerCase()?vd(this,xd,kd).call(this,e[0],t):vd(this,Ad,Ud).call(this,e,t)}loadImageObject(e){const t=new ch;vd(this,Fd,Bd).call(this,e,t,"image")}abort(){const e=Object.keys(Dd(this,Id));for(let t=0;t<e.length;++t)Dd(this,Id)[t].loader.abort(),delete Dd(this,Id)[t]}onloadstart(e){}onprogress(e){}onload(e){}onloaditem(e){}onloadend(e){}onerror(e){}onabort(e){}}function Md(){var e;return wd(this,Ld,(e=Dd(this,Ld),++e)),Dd(this,Ld)}function qd(e){const t=new cd;t.setDefaultCharacterSet(Dd(this,Td)),vd(this,Fd,Bd).call(this,e,t,"image")}function Ud(e,t){const n=new Oc;n.setDefaultCharacterSet(Dd(this,Td)),vd(this,Fd,Bd).call(this,e,n,"image",t)}function Qd(e){const t=new cd;vd(this,Fd,Bd).call(this,[e],t,"state")}function kd(e,t){const n=new Oc;vd(this,Fd,Bd).call(this,[e],n,"state",t)}function Bd(e,t,n,i){const r={loadtype:n},a=vd(this,bd,Md).call(this);r.loadid=a,t.onloadstart=e=>{Dd(this,Id)[a]={loader:t,isFirstItem:!0},vd(this,Rd,Nd).call(this,this.onloadstart,r)(e)},t.onprogress=vd(this,Rd,Nd).call(this,this.onprogress,r),t.onloaditem=e=>{const t={loadtype:n,loadid:a};void 0!==Dd(this,Id)[a]&&(t.isfirstitem=Dd(this,Id)[a].isFirstItem),vd(this,Rd,Nd).call(this,this.onloaditem,t)(e),void 0!==Dd(this,Id)[a]&&Dd(this,Id)[a].isFirstItem&&(Dd(this,Id)[a].isFirstItem=!1)},t.onload=vd(this,Rd,Nd).call(this,this.onload,r),t.onloadend=e=>{delete Dd(this,Id)[a],vd(this,Rd,Nd).call(this,this.onloadend,r)(e)},t.onerror=vd(this,Rd,Nd).call(this,this.onerror,r),t.onabort=vd(this,Rd,Nd).call(this,this.onabort,r);try{t.load(e,i)}catch(e){return this.onerror({error:e,loadid:a}),void this.onloadend({loadid:a})}}function Nd(e,t){return function(n){const i=Object.keys(t);for(let e=0;e<i.length;++e){const r=i[e];n[r]=t[r]}e(n)}}function Wd(e){const t=typeof e;return"function"===t||"object"===t&&!!e}function Vd(e){return Array.isArray(e)}function Gd(e){const t=[],n=Object.keys(e);for(let i=0;i<n.length;++i){const r=n[i];if(null===e[r])continue;const a={name:r},o=Object.keys(e[r]);for(let t=0;t<o.length;++t){const n=o[t];let i=e[r][n];if(Vd(i)){const e=[];for(let t=0;t<i.length;++t)Wd(i[t])?e.push(Gd(i[t])):e.push(i[t]);i=e}else Wd(i)&&(i=Gd(i));a[n]=i}t.push(a)}return t}function zd(e,t,n){Hd(e,t),t.set(e,n)}function Hd(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function jd(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Xd(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Yd(e,t,"get"))}function Yd(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var _d=new WeakMap,Zd=new WeakMap,Kd=new WeakMap,Jd=new WeakSet;class $d{constructor(){var e;Hd(this,e=Jd),e.add(this),zd(this,_d,{writable:!0,value:{}}),zd(this,Zd,{writable:!0,value:new wn}),zd(this,Kd,{writable:!0,value:e=>{Xd(this,Zd).fireEvent(e)}})}length(){return Object.keys(Xd(this,_d)).length}reset(){var e,t;t=[],function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e=this,Yd(e,_d,"set"),t)}get(e){return Xd(this,_d)[e]}setImage(e,t){Xd(this,_d)[e].image=t,Xd(this,Kd).call(this,{type:"imageset",value:[t],dataid:e}),t.addEventListener("imagechange",jd(this,Jd,eS).call(this,e))}addNew(e,t,n){if(void 0!==Xd(this,_d)[e])throw new Error("Index already used in storage: "+e);Xd(this,_d)[e]={image:t,meta:n},t.addEventListener("imagechange",jd(this,Jd,eS).call(this,e))}update(e,t,n){const i=Xd(this,_d)[e];i.image.appendSlice(t);let r="";r=void 0!==n["00020010"]?"00200013":"imageUid",i.meta=function(e,t,n,i){const r={};if(!n)throw new Error("Cannot merge object with an undefined id key: "+n);if(!Object.prototype.hasOwnProperty.call(e,n))throw new Error("Id key not found in first object while merging: "+n+", obj: "+e);if(!Object.prototype.hasOwnProperty.call(t,n))throw new Error("Id key not found in second object while merging: "+n+", obj: "+t);let a=!1;if(Object.prototype.hasOwnProperty.call(e[n],"merged")&&e[n].merged&&(a=!0),!Object.prototype.hasOwnProperty.call(e[n],i))throw new Error("Id value not found in first object while merging: "+n+", valueKey: "+i+", ojb: "+e);if(!Object.prototype.hasOwnProperty.call(t[n],i))throw new Error("Id value not found in second object while merging: "+n+", valueKey: "+i+", ojb: "+t);let o=e[n][i];const s=t[n][i][0];if(r[n]=e[n],a){for(let e=0;e<o.length;++e)if(o[e]===s)throw new Error("The first object already contains id2: "+s+", id1: "+o);r[n][i].push(s)}else{if(o=o[0],o===s)throw new Error("Cannot merge object with same ids: "+o+", id2: "+s);r[n][i].push(s),r[n].merged=!0}const l=Object.keys(e),c=Object.keys(t).filter((function(e){return l.indexOf(e)<0})),u=l.concat(c);for(let l=0,c=u.length;l<c;++l){const c=u[l];if(c!==n){let n,l,u,h,d;if(Object.prototype.hasOwnProperty.call(e,c)&&(n=e[c],Object.prototype.hasOwnProperty.call(n,i)&&(l=n[i])),Object.prototype.hasOwnProperty.call(t,c)&&(u=t[c],Object.prototype.hasOwnProperty.call(u,i)&&(h=u[i])),void 0!==n?d=n:void 0!==u&&(d=u),!Pt(l,h))if(a){if(Vd(l)){d[i]={};for(let e=0;e<o.length;e++)d[i][o[e]]=l}else d[i]=l;d[i][s]=h}else{const e={};e[o]=l,e[s]=h,d[i]=e}r[c]=d}}return r}(i.meta,n,r,"value")}addEventListener(e,t){Xd(this,Zd).add(e,t)}removeEventListener(e,t){Xd(this,Zd).remove(e,t)}}function eS(e){return t=>{t.dataid=e,Xd(this,Kd).call(this,t)}}function tS(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function nS(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,rS(e,t,"get"))}function iS(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,rS(e,t,"set"),n),n}function rS(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var aS=new WeakMap,oS=new WeakMap;class sS{constructor(e){tS(this,aS,{writable:!0,value:void 0}),tS(this,oS,{writable:!0,value:0}),iS(this,aS,e)}wheel(e){let t=52;if(1===e.deltaMode&&(t=5.99),iS(this,oS,nS(this,oS)+e.deltaY),Math.abs(nS(this,oS))<t)return;iS(this,oS,0);const n=e.deltaY<0,i=is(e),r=nS(this,aS).getLayerGroupByDivId(i.groupDivId).getActiveViewLayer().getViewController(),a=r.getImageSize();a.canScroll3D()?n?r.incrementScrollIndex():r.decrementScrollIndex():a.moreThanOne(3)&&(n?r.incrementIndex(3):r.decrementIndex(3))}}function lS(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cS(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function uS(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,dS(e,t,"get"))}function hS(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,dS(e,t,"set"),n),n}function dS(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var SS=new WeakMap,gS=new WeakMap,pS=new WeakMap;function fS(e,t){vS(e,t),t.add(e)}function mS(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function yS(e,t,n){vS(e,t),t.set(e,n)}function vS(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function DS(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,TS(e,t,"get"))}function wS(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function CS(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,TS(e,t,"set"),n),n}function TS(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var IS=new WeakMap,LS=new WeakMap,bS=new WeakMap,PS=new WeakMap,AS=new WeakMap,OS=new WeakSet,xS=new WeakSet;function FS(e){wS(this,xS,RS).call(this);const t=is(e),n=DS(this,IS).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer(),i=n.getViewController(),r=n.displayToPlanePos(e._x,e._y),a=i.getPositionFromPlanePoint(r.x,r.y),o=i.getRescaledImageValue(a);if(void 0!==o){const t=document.createElement("span");t.id="scroll-tooltip",document.getElementById(n.getId()).parentElement.appendChild(t),t.style.left=e._x+10+"px",t.style.top=e._y+10+"px";let r=Lt(o,3).toString();void 0!==i.getPixelUnit()&&(r+=" "+i.getPixelUnit()),t.appendChild(document.createTextNode(r))}}function RS(){const e=document.getElementById("scroll-tooltip");e&&e.remove()}function ES(e,t){const n=e.split(".");if(2!==n.length)throw new Error("Unexpected translation key length.");if("unit"!==n[0])throw new Error("Unexpected translation key prefix.");return{mm:"mm",cm2:"cm²",degree:"°"}[n[1]]}function MS(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function qS(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,QS(e,t,"get"))}function US(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,QS(e,t,"set"),n),n}function QS(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var kS=new WeakMap,BS=new WeakMap;class NS{constructor(e,t){MS(this,kS,{writable:!0,value:void 0}),MS(this,BS,{writable:!0,value:void 0}),US(this,kS,e),US(this,BS,t)}getBegin(){return qS(this,kS)}getEnd(){return qS(this,BS)}equals(e){return null!==e&&this.getBegin().equals(e.getBegin())&&this.getEnd().equals(e.getEnd())}getDeltaX(){return this.getEnd().getX()-this.getBegin().getX()}getDeltaY(){return this.getEnd().getY()-this.getBegin().getY()}getLength(){return Math.sqrt(this.getDeltaX()*this.getDeltaX()+this.getDeltaY()*this.getDeltaY())}getWorldLength(e,t){let n=null;if(null!==e&&null!==t){const i=this.getDeltaX()*e,r=this.getDeltaY()*t;n=Math.sqrt(i*i+r*r)}return n}getMidpoint(){return new Me((this.getBegin().getX()+this.getEnd().getX())/2,(this.getBegin().getY()+this.getEnd().getY())/2)}getSlope(){return this.getDeltaY()/this.getDeltaX()}getIntercept(){return(this.getEnd().getX()*this.getBegin().getY()-this.getBegin().getX()*this.getEnd().getY())/this.getDeltaX()}getInclination(){return 180-180*Math.atan2(this.getDeltaY(),this.getDeltaX())/Math.PI}quantify(e){const t={},n=e.get2DSpacing(),i=this.getWorldLength(n[0],n[1]);return null!==i&&(t.length={value:i,unit:ES("unit.mm")}),t}}function WS(e,t){const n=e.getDeltaX(),i=e.getDeltaY(),r=t.getDeltaX(),a=t.getDeltaY(),o=n*r+i*a,s=n*a-i*r;return 360-(180-180*Math.atan2(s,o)/Math.PI)}function VS(e,t,n){let i=0,r=0,a=0,o=0;if(0!==e.getSlope()){const s=-1/e.getSlope(),l=t.getY()-s*t.getX(),c=n/(2*Math.sqrt(1+s*s));i=t.getX()-c,r=s*i+l,a=t.getX()+c,o=s*a+l}else i=t.getX(),r=t.getY()-n/2,a=t.getX(),o=t.getY()+n/2;return new NS(new Me(i,r),new Me(a,o))}function GS(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function zS(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function HS(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,XS(e,t,"get"))}function jS(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,XS(e,t,"set"),n),n}function XS(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var YS=new WeakMap,_S=new WeakMap;function ZS(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function KS(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function JS(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,eg(e,t,"get"))}function $S(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,eg(e,t,"set"),n),n}function eg(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var tg=new WeakMap,ng=new WeakMap,ig=new WeakMap;function rg(e,t){return function(e){return null!=e&&(e.includes("median")||e.includes("p25")||e.includes("p75"))}(t)?function(e){const t=ag(e);return e.sort((function(e,t){return e-t})),t.median=og(e,.5),t.p25=og(e,.25),t.p75=og(e,.75),t}(e):ag(e)}function ag(e){let t=e[0],n=t,i=0,r=0,a=0;const o=e.length;for(let s=0;s<o;++s)a=e[s],a<t?t=a:a>n&&(n=a),i+=a,r+=a*a;const s=i/o,l=r/o-s*s;return{min:t,max:n,mean:s,stdDev:Math.sqrt(l)}}function og(e,t){if(0===e.length)throw new Error("Empty array provided for percentile calculation.");if(t<0||t>1)throw new Error("Invalid ratio provided for percentile calculation: "+t);if(0===t)return e[0];if(1===t)return e[e.length-1];const n=(e.length-1)*t,i=Math.floor(n),r=e[i];return r+(e[i+1]-r)*(n-i)}function sg(){return Math.random().toString(36).substring(2,15)}function lg(e,t){ug(e,t),t.add(e)}function cg(e,t,n){ug(e,t),t.set(e,n)}function ug(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function hg(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function dg(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,gg(e,t,"get"))}function Sg(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,gg(e,t,"set"),n),n}function gg(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function pg(e,t,n,i){const r=i.applyZoomScale(3);return new(Ta().Ellipse)({x:e,y:t,stroke:"#999",fill:"rgba(100,100,100,0.7",strokeWidth:i.getStrokeWidth(),strokeScaleEnabled:!1,radius:{x:Math.abs(r.x),y:Math.abs(r.y)},name:"anchor",id:n.toString(),dragOnTop:!1,draggable:!0,visible:!1})}var fg=new WeakMap,mg=new WeakMap,yg=new WeakMap,vg=new WeakMap,Dg=new WeakMap,wg=new WeakMap,Cg=new WeakMap,Tg=new WeakSet,Ig=new WeakSet,Lg=new WeakSet,bg=new WeakSet,Pg=new WeakSet,Ag=new WeakSet,Og=new WeakSet;class xg{constructor(e){lg(this,Og),lg(this,Ag),lg(this,Pg),lg(this,bg),lg(this,Lg),lg(this,Ig),lg(this,Tg),cg(this,fg,{writable:!0,value:void 0}),cg(this,mg,{writable:!0,value:null}),cg(this,yg,{writable:!0,value:null}),cg(this,vg,{writable:!0,value:null}),cg(this,Dg,{writable:!0,value:null}),cg(this,wg,{writable:!0,value:!1}),cg(this,Cg,{writable:!0,value:null}),Sg(this,fg,e)}setFactoryList(e){Sg(this,mg,e)}setShape(e){if(Sg(this,vg,e),dg(this,vg)){hg(this,Lg,Eg).call(this);const e=dg(this,vg).getParent(),t=Object.keys(dg(this,mg));Sg(this,yg,null);for(let n=0;n<t.length;++n){const i=new(dg(this,mg)[t[n]]);if(i.isFactoryGroup(e)){Sg(this,yg,i);break}}if(null===dg(this,yg))throw new Error("Could not find a factory to update shape.");hg(this,bg,Mg).call(this)}}setViewController(e){Sg(this,Dg,e)}getShape(){return dg(this,vg)}isActive(){return dg(this,wg)}setDrawEventCallback(e){Sg(this,Cg,e)}enable(){Sg(this,wg,!0),dg(this,vg)&&(hg(this,Ig,Rg).call(this,!0),dg(this,vg).getLayer()&&dg(this,vg).getLayer().draw())}disable(){Sg(this,wg,!1),dg(this,vg)&&(hg(this,Ig,Rg).call(this,!1),dg(this,vg).getLayer()&&dg(this,vg).getLayer().draw())}resetAnchors(){hg(this,Lg,Eg).call(this),hg(this,bg,Mg).call(this),hg(this,Ig,Rg).call(this,!0)}setAnchorsActive(e){let t=null;t=e?e=>{hg(this,Ag,Ug).call(this,e)}:e=>{hg(this,Og,Qg).call(this,e)},hg(this,Tg,Fg).call(this,t)}}function Fg(e){dg(this,vg)&&dg(this,vg).getParent()&&dg(this,vg).getParent().find(".anchor").forEach(e)}function Rg(e){hg(this,Tg,Fg).call(this,(function(t){t.visible(e)}))}function Eg(){hg(this,Tg,Fg).call(this,(function(e){e.remove()}))}function Mg(){if(!dg(this,vg)||!dg(this,vg).getLayer())return;const e=dg(this,vg).getParent(),t=dg(this,yg).getAnchors(dg(this,vg),dg(this,fg).getStyle());for(let n=0;n<t.length;++n)hg(this,Ag,Ug).call(this,t[n]),e.add(t[n])}function qg(e){const t=e.getParent(),n=e.id(),i=e.x(),r=e.y();return{getParent:function(){return t},id:function(){return n},x:function(){return i},y:function(){return r}}}function Ug(e){let t=null;const n=Ga(dg(this,vg));e.on("dragstart.edit",(e=>{const n=e.target;t=hg(this,Pg,qg).call(this,n),e.cancelBubble=!0})),e.on("dragmove.edit",(e=>{const t=e.target,n=is(e.evt);!function(e,t){const n=t.getParent();Ip(t,{x:-n.x(),y:-n.y()},{x:e.x-n.x(),y:e.y-n.y()})}(dg(this,fg).getLayerGroupByDivId(n.groupDivId).getActiveDrawLayer().getBaseSize(),t),dg(this,yg).update(t,dg(this,fg).getStyle(),dg(this,Dg)),t.getLayer()?t.getLayer().draw():re.warn("No layer to draw the anchor!"),e.cancelBubble=!0})),e.on("dragend.edit",(e=>{const i=e.target,r=hg(this,Pg,qg).call(this,i),a=new lo(n,dg(this,yg),t,r,i.getLayer(),dg(this,Dg),dg(this,fg).getStyle());a.onExecute=dg(this,Cg),a.onUndo=dg(this,Cg),a.execute(),dg(this,fg).addToUndoStack(a),t=r,e.cancelBubble=!0})),e.on("mousedown touchstart",(e=>{e.target.moveToTop()})),e.on("mouseover.edit",(e=>{const t=e.target;t.stroke("#ddd"),t.getLayer()?t.getLayer().draw():re.warn("No layer to draw the anchor!")})),e.on("mouseout.edit",(e=>{const t=e.target;t.stroke("#999"),t.getLayer()?t.getLayer().draw():re.warn("No layer to draw the anchor!")}))}function Qg(e){e.off("dragstart.edit"),e.off("dragmove.edit"),e.off("dragend.edit"),e.off("mousedown touchstart"),e.off("mouseover.edit"),e.off("mouseout.edit")}function kg(e,t){Wg(e,t),t.add(e)}function Bg(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ng(e,t,n){Wg(e,t),t.set(e,n)}function Wg(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Vg(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Gg(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Hg(e,t,"get"))}function zg(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Hg(e,t,"set"),n),n}function Hg(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var jg=new WeakMap,Xg=new WeakMap,Yg=new WeakMap,_g=new WeakMap,Zg=new WeakMap,Kg=new WeakMap,Jg=new WeakMap,$g=new WeakMap,ep=new WeakMap,tp=new WeakMap,np=new WeakMap,ip=new WeakMap,rp=new WeakMap,ap=new WeakMap,op=new WeakMap,sp=new WeakMap,lp=new WeakMap,cp=new WeakSet,up=new WeakSet,hp=new WeakSet,dp=new WeakSet,Sp=new WeakSet,gp=new WeakSet,pp=new WeakSet,fp=new WeakMap;function mp(e,t){const n=t.getActiveDrawLayer().getKonvaLayer();Gg(this,tp)&&(Gg(this,tp).destroy(),zg(this,tp,null));const i=t.getActiveViewLayer().getViewController();zg(this,tp,Gg(this,$g).create(e,Gg(this,Zg),i)),Gg(this,tp).getChildren(vo)[0].listening(!1),n.listening(!1),n.add(Gg(this,tp)),n.draw()}function yp(e,t){const n=t.getActiveDrawLayer().getKonvaLayer();Gg(this,tp)&&(Gg(this,tp).destroy(),zg(this,tp,null));const i=t.getActiveViewLayer().getViewController(),r=t.getActiveDrawLayer().getDrawController(),a=Gg(this,$g).create(e,Gg(this,Zg),i);a.id(sg()),r.getCurrentPosGroup().add(a),n.listening(!0),zg(this,ep,new _a(a,Gg(this,np),n)),Gg(this,ep).onExecute=Gg(this,fp),Gg(this,ep).onUndo=Gg(this,fp),Gg(this,ep).execute(),Gg(this,jg).addToUndoStack(Gg(this,ep)),this.setShapeOn(a,t)}function vp(e){Vg(this,dp,Dp).call(this,!0,e)}function Dp(e,t){const n=t.getActiveDrawLayer().getDrawController().getCurrentPosGroup().getChildren();e?n.forEach((e=>{this.setShapeOn(e,t)})):n.forEach((e=>{Vg(this,Sp,wp).call(this,e)}));const i=t.getActiveDrawLayer().getKonvaLayer();0!==n.length&&i.listening(!0),i.draw()}function wp(e){e.off("mouseover"),e.off("mouseout"),e.draggable(!1),e.off("dragstart.draw"),e.off("dragmove.draw"),e.off("dragend.draw"),e.off("dblclick")}function Cp(e,t){const n=t.getActiveDrawLayer().getKonvaStage();return{x:n.offset().x+e.x/n.scale().x,y:n.offset().y+e.y/n.scale().y}}function Tp(){if(void 0!==Gg(this,op)&&(document.body.style.cursor=Gg(this,op)),void 0!==Gg(this,ap)){Gg(this,ap).opacity(1);const e=Gg(this,Zg).getLineColour();Gg(this,ap).getChildren(Io).forEach((function(t){t.stroke(e)}))}}function Ip(e,t,n){let i=!1;return e.x()<t.x?(e.x(t.x),i=!0):e.x()>n.x&&(e.x(n.x),i=!0),e.y()<t.y?(e.y(t.y),i=!0):e.y()>n.y&&(e.y(n.y),i=!0),i}function Lp(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,bp(e,t,"get"))}function bp(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Pp=new WeakMap;class Ap{constructor(){var e,t,n;n={writable:!0,value:[]},function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e=this,t=Pp),t.set(e,n)}getPoint(e){return Lp(this,Pp)[e]}getLength(){return Lp(this,Pp).length}addPoint(e){Lp(this,Pp).push(e)}addPoints(e){var t,n,i;t=this,n=Pp,i=Lp(this,Pp).concat(e),function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(t,bp(t,n,"set"),i)}}class Op{getGroupName(){return"roi-group"}getNPoints(){}getTimeout(){return 100}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=new Ap;i.addPoints(e);const r=[];for(let e=0;e<i.getLength();++e)r.push(i.getPoint(e).getX()),r.push(i.getPoint(e).getY());const a=new(Ta().Line)({points:r,stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape",closed:!0}),o=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),name:"text"});let s="";s="",o.setText(""),o.meta={textExpr:"",quantification:{}};const l=new(Ta().Label)({x:i.getPoint(0).getX(),y:i.getPoint(0).getY()+t.scale(10),scale:t.applyZoomScale(1),visible:0!=="".length,name:"label"});l.add(o),l.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const c=new(Ta().Group);return c.name(this.getGroupName()),c.add(l),c.add(a),c.visible(!0),c}getAnchors(e,t){const n=e.points(),i=[];for(let r=0;r<n.length;r+=2){const a=n[r]+e.x(),o=n[r+1]+e.y(),s=r.toString();i.push(pg(a,o,s,t))}return i}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"label"===e.name()}))[0],o=i.getChildren((function(t){return t.id()===e.id()}))[0];o.x(e.x()),o.y(e.y());const s=r.points();s[e.id()]=e.x()-r.x(),s[e.id()+1]=e.y()-r.y(),r.points(s);const l=a.getText();l.setText(l.meta.textExpr);const c={x:s[0]+r.x(),y:s[1]+r.y()+t.scale(10)};a.position(c)}}var xp=a(812),Fp=a.n(xp);function Rp(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ep(e,t){qp(e,t),t.add(e)}function Mp(e,t,n){qp(e,t),t.set(e,n)}function qp(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Up(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Qp(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Bp(e,t,"get"))}function kp(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Bp(e,t,"set"),n),n}function Bp(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Np=new WeakMap,Wp=new WeakMap,Vp=new WeakMap,Gp=new WeakMap,zp=new WeakMap,Hp=new WeakMap,jp=new WeakMap,Xp=new WeakMap,Yp=new WeakMap,_p=new WeakMap,Zp=new WeakMap,Kp=new WeakMap,Jp=new WeakMap,$p=new WeakMap,ef=new WeakMap,tf=new WeakMap,nf=new WeakMap,rf=new WeakMap,af=new WeakMap,of=new WeakSet,sf=new WeakSet,lf=new WeakMap;function cf(e,t,n){kp(this,$p,[]);const i={data:Qp(this,zp).data,width:Qp(this,zp).width,height:Qp(this,zp).height,bytes:4};kp(this,Hp,Fp().floodFill(i,e.x,e.y,t)),kp(this,Hp,Fp().gaussBlurOnlyBorder(Qp(this,Hp),Qp(this,Wp)));let r=Fp().traceContours(Qp(this,Hp));if(r=Fp().simplifyContours(r,Qp(this,Vp),Qp(this,Gp)),r.length>0&&r[0].points[0].x){if(n)return r[0].points;for(let e=0,t=r[0].points.length;e<t;e++)Qp(this,$p).push(new Me(r[0].points[e].x,r[0].points[e].y));return Qp(this,$p)}return[]}function uf(e,t,n){if(kp(this,Jp,Up(this,of,cf).call(this,e,t,!1)),Qp(this,Jp)){const e=new Op;kp(this,Zp,e.create(Qp(this,Jp),Qp(this,nf))),Qp(this,Zp).id(sg());const t=n.getActiveDrawLayer();return t.getDrawController().getCurrentPosGroup().add(Qp(this,Zp)),kp(this,_p,new _a(Qp(this,Zp),"floodfill",t.getKonvaLayer())),Qp(this,_p).onExecute=Qp(this,lf),Qp(this,_p).onUndo=Qp(this,lf),Qp(this,_p).execute(),Qp(this,Np).addToUndoStack(Qp(this,_p)),!0}return!1}class hf{constructor(e,t){this.pointArray=e?e.slice():[],this.controlPointIndexArray=t?t.slice():[]}getPoint(e){return this.pointArray[e]}isControlPoint(e){const t=this.pointArray.indexOf(e);if(-1!==t)return-1!==this.controlPointIndexArray.indexOf(t);throw new Error("Error: isControlPoint called with not in list point.")}getLength(){return this.pointArray.length}addPoint(e){this.pointArray.push(e)}addControlPoint(e){const t=this.pointArray.indexOf(e);if(-1===t)throw new Error("Cannot mark a non registered point as control point.");this.controlPointIndexArray.push(t)}addPoints(e){this.pointArray=this.pointArray.concat(e)}appenPath(e){const t=this.pointArray.length;this.pointArray=this.pointArray.concat(e.pointArray);const n=[];for(let i=0;i<e.controlPointIndexArray.length;++i)n[i]=e.controlPointIndexArray[i]+t;this.controlPointIndexArray=this.controlPointIndexArray.concat(n)}}class df{constructor(e,t){this.bucketCount=1<<e,this.mask=this.bucketCount-1,this.size=0,this.loc=0,this.cost=void 0!==t?t:function(e){return e},this.buckets=this.buildArray(this.bucketCount)}push(e){const t=this.getBucket(e);e.next=this.buckets[t],this.buckets[t]=e,this.size++}pop(){if(0===this.size)throw new Error("Cannot pop, bucketQueue is empty.");for(;null===this.buckets[this.loc];)this.loc=(this.loc+1)%this.bucketCount;const e=this.buckets[this.loc];return this.buckets[this.loc]=e.next,e.next=null,this.size--,e}remove(e){if(!e)return!1;const t=this.getBucket(e);let n=this.buckets[t];for(;null!==n&&(null===n.next||e.x!==n.next.x||e.y!==n.next.y);)n=n.next;return null!==n&&(n.next=n.next.next,this.size--,!0)}isEmpty(){return 0===this.size}getBucket(e){return this.cost(e)&this.mask}buildArray(e){const t=new Array(e);for(let e=0;e<t.length;e++)t[e]=null;return t}}const Sf=2/(3*Math.PI);function gf(e,t,n,i,r){const a=e[i][n],o=t[i][n];let s=Math.sqrt(a*a+o*o);s=Math.max(s,1e-100),r.x=a/s,r.y=o/s}class pf{constructor(){this.width=-1,this.height=-1,this.curPoint=null,this.searchGranBits=8,this.searchGran=1<<this.searchGranBits,this.pointsPerPost=500,this.greyscale=null,this.laplace=null,this.gradient=null,this.gradX=null,this.gradY=null,this.parents=null,this.working=!1,this.trained=!1,this.trainingPoints=null,this.edgeWidth=2,this.trainingLength=32,this.edgeGran=256,this.edgeTraining=null,this.gradPointsNeeded=32,this.gradGran=1024,this.gradTraining=null,this.insideGran=256,this.insideTraining=null,this.outsideGran=256,this.outsideTraining=null}getTrainingIdx(e,t){return Math.round((e-1)*t)}getTrainedEdge(e){return this.edgeTraining[this.getTrainingIdx(this.edgeGran,e)]}getTrainedGrad(e){return this.gradTraining[this.getTrainingIdx(this.gradGran,e)]}getTrainedInside(e){return this.insideTraining[this.getTrainingIdx(this.insideGran,e)]}getTrainedOutside(e){return this.outsideTraining[this.getTrainingIdx(this.outsideGran,e)]}setWorking(e){this.working=e}setDimensions(e,t){this.width=e,this.height=t}setData(e){if(-1===this.width||-1===this.height)throw new Error("Dimensions have not been set.");this.greyscale=function(e,t,n){const i={};for(let r=0;r<n;r++){i[r]=[];for(let n=0;n<t;n++){const a=4*(r*t+n);i[r][n]=(e[a]+e[a+1]+e[a+2])/765}}return i.dx=function(e,t){return e+1===this[t].length&&e--,this[t][e+1]-this[t][e]},i.dy=function(e,t){return t+1===this.length&&t--,this[t][e]-this[t+1][e]},i.gradMagnitude=function(e,t){const n=this.dx(e,t),i=this.dy(e,t);return Math.sqrt(n*n+i*i)},i.laplace=function(e,t){let n=-16*this[t][e];return n+=this[t-2][e],n+=this[t-1][e-1]+2*this[t-1][e]+this[t-1][e+1],n+=this[t][e-2]+2*this[t][e-1]+2*this[t][e+1]+this[t][e+2],n+=this[t+1][e-1]+2*this[t+1][e]+this[t+1][e+1],n+=this[t+2][e],n},i}(e,this.width,this.height),this.laplace=function(e){const t=[];t[0]=[],t[1]=[];for(let n=1;n<e.length;n++)t[0][n]=1,t[1][n]=1;for(let n=2;n<e.length-2;n++){t[n]=[],t[n][0]=1,t[n][1]=1;for(let i=2;i<e[n].length-2;i++)t[n][i]=e.laplace(i,n)>.33?0:1;t[n][e[n].length-2]=1,t[n][e[n].length-1]=1}t[e.length-2]=[],t[e.length-1]=[];for(let n=1;n<e.length;n++)t[e.length-2][n]=1,t[e.length-1][n]=1;return t}(this.greyscale),this.gradient=function(e){const t=[];let n=0,i=0,r=0;for(r=0;r<e.length-1;r++){for(t[r]=[],i=0;i<e[r].length-1;i++)t[r][i]=e.gradMagnitude(i,r),n=Math.max(t[r][i],n);t[r][e[r].length-1]=t[r][e.length-2]}t[e.length-1]=[];for(let n=0;n<t[0].length;n++)t[e.length-1][n]=t[e.length-2][n];for(r=0;r<t.length;r++)for(i=0;i<t[r].length;i++)t[r][i]=1-t[r][i]/n;return t}(this.greyscale),this.gradX=function(e){const t=[];for(let n=0;n<e.length;n++){t[n]=[];for(let i=0;i<e[n].length-1;i++)t[n][i]=e.dx(i,n);t[n][e[n].length-1]=t[n][e[n].length-2]}return t}(this.greyscale),this.gradY=function(e){const t=[];for(let n=0;n<e.length-1;n++){t[n]=[];for(let i=0;i<e[n].length;i++)t[n][i]=e.dy(i,n)}t[e.length-1]=[];for(let n=0;n<e[0].length;n++)t[e.length-1][n]=t[e.length-2][n];return t}(this.greyscale);const t=function(e,t,n,i){const r={inside:[],outside:[]},a={x:-1,y:-1};for(let o=0;o<t.length;o++){r.inside[o]=[],r.outside[o]=[];for(let s=0;s<t[o].length;s++){gf(t,n,s,o,a);let l=Math.round(s+e*a.y),c=Math.round(o-e*a.x),u=Math.round(s-e*a.y),h=Math.round(o+e*a.x);l=Math.max(Math.min(l,t[o].length-1),0),u=Math.max(Math.min(u,t[o].length-1),0),c=Math.max(Math.min(c,t.length-1),0),h=Math.max(Math.min(h,t.length-1),0),r.inside[o][s]=i[c][l],r.outside[o][s]=i[h][u]}}return r}(this.edgeWidth,this.gradX,this.gradY,this.greyscale);this.inside=t.inside,this.outside=t.outside,this.edgeTraining=[],this.gradTraining=[],this.insideTraining=[],this.outsideTraining=[]}findTrainingPoints(e){const t=[];if(null!==this.parents)for(let n=0;n<this.trainingLength&&e;n++)t.push(e),e=this.parents[e.y][e.x];return t}resetTraining(){this.trained=!1}doTraining(e){if(this.trainingPoints=this.findTrainingPoints(e),this.trainingPoints.length<8)return;const t=[];this.calculateTraining(t,this.edgeGran,this.greyscale,this.edgeTraining),this.calculateTraining(t,this.gradGran,this.gradient,this.gradTraining),this.calculateTraining(t,this.insideGran,this.inside,this.insideTraining),this.calculateTraining(t,this.outsideGran,this.outside,this.outsideTraining),this.trainingPoints.length<this.gradPointsNeeded&&this.addInStaticGrad(this.trainingPoints.length,this.gradPointsNeeded),this.trained=!0}calculateTraining(e,t,n,i){let r=0;for(e.length=t,r=0;r<t;r++)e[r]=0;let a=1;for(r=0;r<this.trainingPoints.length;r++){const i=this.trainingPoints[r],o=this.getTrainingIdx(t,n[i.y][i.x]);e[o]+=1,a=Math.max(a,e[o])}for(r=0;r<t;r++)e[r]=1-e[r]/a;!function(e,t){t[0]=.4*e[0]+.5*e[1]+.1*e[1],t[1]=.25*e[0]+.4*e[1]+.25*e[2]+.1*e[3];for(let n=2;n<e.length-2;n++)t[n]=.05*e[n-2]+.25*e[n-1]+.4*e[n]+.25*e[n+1]+.05*e[n+2];const n=e.length;t[n-2]=.25*e[n-1]+.4*e[n-2]+.25*e[n-3]+.1*e[n-4],t[n-1]=.4*e[n-1]+.5*e[n-2]+.1*e[n-3]}(e,i)}addInStaticGrad(e,t){for(let n=0;n<this.gradGran;n++)this.gradTraining[n]=Math.min(this.gradTraining[n],1-n*(t-e)/(t*this.gradGran))}gradDirection(e,t,n,i){return function(e,t,n,i,r,a){const o={x:-1,y:-1},s={x:-1,y:-1};gf(e,t,n,i,o),gf(e,t,r,a,s);let l=o.y*(r-n)-o.x*(a-i),c=s.y*(r-n)-s.x*(a-i);return l<0&&(l=-l,c=-c),n!==r&&i!==a&&(l*=Math.SQRT1_2,c*=Math.SQRT1_2),Sf*(Math.acos(l)+Math.acos(c))}(this.gradX,this.gradY,e,t,n,i)}dist(e,t,n,i){let r=this.gradient[i][n];e!==n&&t!==i||(r*=Math.SQRT1_2);const a=this.laplace[i][n],o=this.gradDirection(e,t,n,i);return this.trained?.3*this.getTrainedGrad(r)+.3*a+.1*(o+this.getTrainedEdge(this.greyscale[t][e])+this.getTrainedInside(this.inside[t][e])+this.getTrainedOutside(this.outside[t][e])):.43*r+.43*a+.11*o}adj(e){const t=[],n=Math.max(e.x-1,0),i=Math.max(e.y-1,0),r=Math.min(e.x+1,this.greyscale[0].length-1),a=Math.min(e.y+1,this.greyscale.length-1);let o=0;for(let s=i;s<=a;s++)for(let i=n;i<=r;i++)i===e.x&&s===e.y||(t[o++]={x:i,y:s});return t}setPoint(e){this.setWorking(!0),this.curPoint=e;let t=0,n=0;for(this.visited=[],n=0;n<this.height;n++)for(this.visited[n]=[],t=0;t<this.width;t++)this.visited[n][t]=!1;for(this.parents=[],n=0;n<this.height;n++)this.parents[n]=[];for(this.cost=[],n=0;n<this.height;n++)for(this.cost[n]=[],t=0;t<this.width;t++)this.cost[n][t]=Number.MAX_VALUE;this.pq=new df(this.searchGranBits,(function(e){return Math.round(this.searchGran*this.costArr[e.y][e.x])})),this.pq.searchGran=this.searchGran,this.pq.costArr=this.cost,this.pq.push(e),this.cost[e.y][e.x]=0}doWork(){if(!this.working)return;this.timeout=null;let e=0;const t=[];for(;!this.pq.isEmpty()&&e<this.pointsPerPost;){const n=this.pq.pop();t.push(n),t.push(this.parents[n.y][n.x]),this.visited[n.y][n.x]=!0;const i=this.adj(n);for(let e=0;e<i.length;e++){const t=i[e],r=this.cost[n.y][n.x]+this.dist(n.x,n.y,t.x,t.y);r<this.cost[t.y][t.x]&&(this.cost[t.y][t.x]!==Number.MAX_VALUE&&this.pq.remove(t),this.cost[t.y][t.x]=r,this.parents[t.y][t.x]=n,this.pq.push(t))}e++}return t}}function ff(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function mf(e,t){vf(e,t),t.add(e)}function yf(e,t,n){vf(e,t),t.set(e,n)}function vf(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Df(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function wf(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Tf(e,t,"get"))}function Cf(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Tf(e,t,"set"),n),n}function Tf(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var If=new WeakMap,Lf=new WeakMap,bf=new WeakMap,Pf=new WeakMap,Af=new WeakMap,Of=new WeakMap,xf=new WeakMap,Ff=new WeakMap,Rf=new WeakMap,Ef=new WeakMap,Mf=new WeakSet,qf=new WeakSet,Uf=new WeakMap,Qf=new WeakSet,kf=new WeakMap;function Bf(e){const t=e.get(1);for(let e=0;e<t;++e)wf(this,Ff)[e]=[]}function Nf(){Cf(this,Of,new hf),Cf(this,xf,new hf)}function Wf(){wf(this,kf).call(this,{type:"drawcreate",id:wf(this,Pf).id()}),wf(this,bf).onExecute=wf(this,kf),wf(this,bf).onUndo=wf(this,kf),wf(this,If).addToUndoStack(wf(this,bf)),Cf(this,Lf,!1)}function Vf(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function Gf(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Hf(e,t,"get"))}function zf(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Hf(e,t,"set"),n),n}function Hf(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var jf=new WeakMap,Xf=new WeakMap;class Yf{constructor(e,t){Vf(this,jf,{writable:!0,value:void 0}),Vf(this,Xf,{writable:!0,value:void 0}),zf(this,jf,e),zf(this,Xf,t)}getCenter(){return Gf(this,jf)}getRadius(){return Gf(this,Xf)}equals(e){return null!==e&&this.getCenter().equals(e.getCenter())&&this.getRadius()===e.getRadius()}getSurface(){return Math.PI*this.getRadius()*this.getRadius()}getWorldSurface(e,t){return function(e,t,n){let i=null;return null!==t&&null!==n&&(i=e*t*n),i}(this.getSurface(),e,t)}getRound(){const e=this.getCenter().getX(),t=this.getCenter().getY(),n=this.getRadius(),i=Math.pow(n,2),r=t+n,a=[];for(let o=t-n;o<r;++o){const n=i-Math.pow(o-t,2);if(Math.abs(n)<1e-7)continue;const r=Math.sqrt(n);r<.5||a.push([[Math.round(e-r),Math.round(o)],[Math.round(e+r),Math.round(o)]])}return a}quantify(e,t){const n={},i=e.get2DSpacing(),r=this.getWorldSurface(i[0],i[1]);if(null!==r&&(n.surface={value:r/100,unit:ES("unit.cm2")}),e.canQuantifyImage()){const i=this.getRound();if(0!==i.length){const r=rg(e.getImageVariableRegionValues(i),t);n.min={value:r.min,unit:""},n.max={value:r.max,unit:""},n.mean={value:r.mean,unit:""},n.stdDev={value:r.stdDev,unit:""},void 0!==r.median&&(n.median={value:r.median,unit:""}),void 0!==r.p25&&(n.p25={value:r.p25,unit:""}),void 0!==r.p75&&(n.p75={value:r.p75,unit:""})}}return n}}function _f(e,t){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.add(e)}function Zf(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}var Kf=new WeakSet,Jf=new WeakSet;function $f(e,t){const n=e.getChildren((function(e){return"shape"===e.name()}))[0],i=e.getChildren((function(e){return"label"===e.name()}))[0],r=new Me(e.x()+n.x(),e.y()+n.y()),a=new Yf(r,n.radius()),o=i.getText(),s=a.quantify(t,wt(o.meta.textExpr));o.setText(Ct(o.meta.textExpr,s)),o.meta.quantification=s}function em(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function tm(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,im(e,t,"get"))}function nm(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,im(e,t,"set"),n),n}function im(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var rm=new WeakMap,am=new WeakMap,om=new WeakMap;class sm{constructor(e,t,n){em(this,rm,{writable:!0,value:void 0}),em(this,am,{writable:!0,value:void 0}),em(this,om,{writable:!0,value:void 0}),nm(this,rm,e),nm(this,am,t),nm(this,om,n)}getCenter(){return tm(this,rm)}getA(){return tm(this,am)}getB(){return tm(this,om)}equals(e){return null!==e&&this.getCenter().equals(e.getCenter())&&this.getA()===e.getA()&&this.getB()===e.getB()}getSurface(){return Math.PI*this.getA()*this.getB()}getWorldSurface(e,t){return function(e,t,n){let i=null;return null!==t&&null!==n&&(i=e*t*n),i}(this.getSurface(),e,t)}getRound(){const e=this.getCenter().getX(),t=this.getCenter().getY(),n=this.getA(),i=this.getB(),r=n/i,a=Math.pow(i,2),o=t+i,s=[];for(let n=t-i;n<o;++n){const i=a-Math.pow(n-t,2);if(Math.abs(i)<1e-7)continue;const o=r*Math.sqrt(i);o<.5||s.push([[Math.round(e-o),Math.round(n)],[Math.round(e+o),Math.round(n)]])}return s}quantify(e,t){const n={},i=e.get2DSpacing(),r=this.getWorldSurface(i[0],i[1]);if(null!==r&&(n.surface={value:r/100,unit:ES("unit.cm2")}),e.canQuantifyImage()){const i=this.getRound();if(0!==i.length){const r=rg(e.getImageVariableRegionValues(i),t);n.min={value:r.min,unit:""},n.max={value:r.max,unit:""},n.mean={value:r.mean,unit:""},n.stdDev={value:r.stdDev,unit:""},void 0!==r.median&&(n.median={value:r.median,unit:""}),void 0!==r.p25&&(n.p25={value:r.p25,unit:""}),void 0!==r.p75&&(n.p75={value:r.p75,unit:""})}}return n}}function lm(e,t){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.add(e)}function cm(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}var um=new WeakSet,hm=new WeakSet;function dm(e,t){const n=e.getChildren((function(e){return"shape"===e.name()}))[0],i=e.getChildren((function(e){return"label"===e.name()}))[0],r=new Me(e.x()+n.x(),e.y()+n.y()),a=new sm(r,n.radius().x,n.radius().y),o=i.getText(),s=a.quantify(t,wt(o.meta.textExpr));o.setText(Ct(o.meta.textExpr,s)),o.meta.quantification=s}function Sm(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function gm(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,fm(e,t,"get"))}function pm(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,fm(e,t,"set"),n),n}function fm(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var mm=new WeakMap,ym=new WeakMap;class vm{constructor(e,t){Sm(this,mm,{writable:!0,value:void 0}),Sm(this,ym,{writable:!0,value:void 0}),pm(this,mm,new Me(Math.min(e.getX(),t.getX()),Math.min(e.getY(),t.getY()))),pm(this,ym,new Me(Math.max(e.getX(),t.getX()),Math.max(e.getY(),t.getY())))}getBegin(){return gm(this,mm)}getEnd(){return gm(this,ym)}equals(e){return null!==e&&this.getBegin().equals(e.getBegin())&&this.getEnd().equals(e.getEnd())}getSurface(){const e=this.getBegin(),t=this.getEnd();return Math.abs(t.getX()-e.getX())*Math.abs(t.getY()-e.getY())}getWorldSurface(e,t){return function(e,t,n){let i=null;return null!==t&&null!==n&&(i=e*t*n),i}(this.getSurface(),e,t)}getRealWidth(){return this.getEnd().getX()-this.getBegin().getX()}getRealHeight(){return this.getEnd().getY()-this.getBegin().getY()}getWidth(){return Math.abs(this.getRealWidth())}getHeight(){return Math.abs(this.getRealHeight())}getRound(){return{min:this.getBegin().getRound(),max:this.getEnd().getRound()}}quantify(e,t){const n={},i=e.get2DSpacing(),r=this.getWorldSurface(i[0],i[1]);if(null!==r&&(n.surface={value:r/100,unit:ES("unit.cm2")}),e.canQuantifyImage()){const i=this.getRound(),r=rg(e.getImageRegionValues(i.min,i.max),t);n.min={value:r.min,unit:""},n.max={value:r.max,unit:""},n.mean={value:r.mean,unit:""},n.stdDev={value:r.stdDev,unit:""},void 0!==r.median&&(n.median={value:r.median,unit:""}),void 0!==r.p25&&(n.p25={value:r.p25,unit:""}),void 0!==r.p75&&(n.p75={value:r.p75,unit:""})}return n}}function Dm(e,t){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.add(e)}function wm(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}var Cm=new WeakSet,Tm=new WeakSet;function Im(e,t){const n=e.getChildren((function(e){return"shape"===e.name()}))[0],i=e.getChildren((function(e){return"label"===e.name()}))[0],r=new Me(e.x()+n.x(),e.y()+n.y()),a=new Me(r.getX()+n.width(),r.getY()+n.height()),o=new vm(r,a),s=i.getText(),l=o.quantify(t,wt(s.meta.textExpr));s.setText(Ct(s.meta.textExpr,l)),s.meta.quantification=l}function Lm(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function bm(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Am(e,t,"set"),n),n}function Pm(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Am(e,t,"get"))}function Am(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Om=new WeakMap,xm=new WeakMap,Fm=new WeakMap;class Rm{constructor(){Lm(this,Om,{writable:!0,value:0}),Lm(this,xm,{writable:!0,value:0}),Lm(this,Fm,{writable:!0,value:null})}getMin(){return Pm(this,Om)}setMin(e){bm(this,Om,e)}getMax(){return Pm(this,xm)}setMax(e){bm(this,xm,e)}getName(){return"Threshold"}setOriginalImage(e){bm(this,Fm,e)}getOriginalImage(){return Pm(this,Fm)}update(){const e=this.getOriginalImage(),t=e.getDataRange().min;return e.transform((e=>e<this.getMin()||e>this.getMax()?t:e))}}var Em=new WeakMap;class Mm{constructor(){Lm(this,Em,{writable:!0,value:null})}getName(){return"Sharpen"}setOriginalImage(e){bm(this,Em,e)}getOriginalImage(){return Pm(this,Em)}update(){return this.getOriginalImage().convolute2D([0,-1,0,-1,5,-1,0,-1,0])}}var qm=new WeakMap;class Um{constructor(){Lm(this,qm,{writable:!0,value:null})}getName(){return"Sobel"}setOriginalImage(e){bm(this,qm,e)}getOriginalImage(){return Pm(this,qm)}update(){const e=this.getOriginalImage(),t=e.convolute2D([1,0,-1,2,0,-2,1,0,-1]),n=e.convolute2D([1,2,1,0,0,0,-1,-2,-1]);return t.compose(n,(function(e,t){return Math.sqrt(e*e+t*t)}))}}function Qm(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function km(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,Nm(e,t,"get"))}function Bm(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,Nm(e,t,"set"),n),n}function Nm(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Wm=new WeakMap,Vm=new WeakMap,Gm=new WeakMap,zm=new WeakMap,Hm=new WeakMap,jm=new WeakMap,Xm=new WeakMap,Ym=new WeakMap,_m=new WeakMap,Zm=new WeakMap,Km=new WeakMap,Jm=new WeakMap,$m=new WeakMap,ey=new WeakMap,ty=new WeakMap,ny=new WeakMap,iy=new WeakMap,ry=new WeakMap;class ay{constructor(e,t){Qm(this,iy,{writable:!0,value:void 0}),Qm(this,ry,{writable:!0,value:void 0}),Bm(this,iy,e),Bm(this,ry,t)}getName(){return"Filter-"+km(this,iy).getName()}execute(){km(this,ry).setLastImage(km(this,iy).update()),km(this,ry).render(0);const e={type:"filterrun",id:this.getName()};this.onExecute(e)}undo(){km(this,ry).setLastImage(km(this,iy).getOriginalImage()),km(this,ry).render(0);const e={type:"filterundo",id:this.getName()};this.onUndo(e)}onExecute(e){}onUndo(e){}}const oy={WindowLevel:class{constructor(e){cS(this,SS,{writable:!0,value:void 0}),cS(this,gS,{writable:!0,value:!1}),cS(this,pS,{writable:!0,value:void 0}),lS(this,"mousedown",(e=>{hS(this,gS,!0),this.x0=e._x,this.y0=e._y})),lS(this,"mousemove",(e=>{if(!uS(this,gS))return;const t=is(e),n=uS(this,SS).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().getViewController(),i=e._x-this.x0,r=this.y0-e._y,a=n.getImageRescaledDataRange(),o=.01*(a.max-a.min),s=parseInt(n.getWindowLevel().center,10),l=parseInt(n.getWindowLevel().width,10),c=s+Math.round(r*o);let u=l+Math.round(i*o);var h;u=(h=u)<1?1:h,n.addWindowLevelPresets({manual:{wl:[new N(c,u)],name:"manual"}}),n.setWindowLevelPreset("manual"),this.x0=e._x,this.y0=e._y})),lS(this,"mouseup",(e=>{uS(this,gS)&&hS(this,gS,!1)})),lS(this,"mouseout",(e=>{this.mouseup(e)})),lS(this,"touchstart",(e=>{this.mousedown(e)})),lS(this,"touchmove",(e=>{this.mousemove(e)})),lS(this,"touchend",(e=>{this.mouseup(e)})),lS(this,"dblclick",(e=>{const t=is(e),n=uS(this,SS).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer(),i=n.displayToPlaneIndex(e._x,e._y),r=n.getViewController(),a=uS(this,SS).getImage(n.getDataIndex());r.setWindowLevel(a.getRescaledValueAtIndex(r.getCurrentIndex().getWithNew2D(i.get(0),i.get(1))),parseInt(r.getWindowLevel().width,10))})),lS(this,"wheel",(e=>{uS(this,pS).wheel(e)})),lS(this,"keydown",(e=>{e.context="WindowLevel",uS(this,SS).onKeydown(e)})),hS(this,SS,e),hS(this,pS,new sS(e))}activate(e){}init(){}},Scroll:class{constructor(e){fS(this,xS),fS(this,OS),yS(this,IS,{writable:!0,value:void 0}),yS(this,LS,{writable:!0,value:!1}),yS(this,bS,{writable:!0,value:void 0}),yS(this,PS,{writable:!0,value:void 0}),yS(this,AS,{writable:!0,value:!1}),mS(this,"mousedown",(e=>{wS(this,xS,RS).call(this);const t=is(e),n=DS(this,IS).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer(),i=n.getViewController();i.isPlaying()&&i.stop(),CS(this,LS,!0),this.x0=e._x,this.y0=e._y;const r=n.displayToPlanePos(e._x,e._y),a=i.getPositionFromPlanePoint(r.x,r.y);i.setCurrentPosition(a)})),mS(this,"mousemove",(e=>{if(!DS(this,LS))return void(DS(this,AS)&&wS(this,OS,FS).call(this,e));const t=is(e),n=DS(this,IS).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().getViewController(),i=e._y-this.y0,r=Math.abs(i)>15;r&&n.canScroll()&&(i>0?n.decrementScrollIndex():n.incrementScrollIndex());const a=e._x-this.x0,o=Math.abs(a)>15,s=n.getImageSize();o&&s.moreThanOne(3)&&(a>0?n.incrementIndex(3):n.decrementIndex(3)),o&&(this.x0=e._x),r&&(this.y0=e._y)})),mS(this,"mouseup",(e=>{DS(this,LS)&&CS(this,LS,!1)})),mS(this,"mouseout",(e=>{this.mouseup(e),wS(this,xS,RS).call(this)})),mS(this,"touchstart",(e=>{CS(this,PS,setTimeout(this.dblclick,500)),this.mousedown(e)})),mS(this,"touchmove",(e=>{null!==DS(this,PS)&&(clearTimeout(DS(this,PS)),CS(this,PS,null)),this.mousemove(e)})),mS(this,"touchend",(e=>{null!==DS(this,PS)&&(clearTimeout(DS(this,PS)),CS(this,PS,null)),this.mouseup(e)})),mS(this,"wheel",(e=>{DS(this,bS).wheel(e)})),mS(this,"keydown",(e=>{e.context="Scroll",DS(this,IS).onKeydown(e)})),mS(this,"dblclick",(e=>{const t=is(e);DS(this,IS).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().getViewController().play()})),CS(this,IS,e),CS(this,bS,new sS(e))}activate(e){e||wS(this,xS,RS).call(this)}setFeatures(e){void 0!==e.displayTooltip&&CS(this,AS,e.displayTooltip)}init(){}},ZoomAndPan:class{constructor(e){zS(this,YS,{writable:!0,value:void 0}),zS(this,_S,{writable:!0,value:!1}),GS(this,"mousedown",(e=>{jS(this,_S,!0),this.x0=e._x,this.y0=e._y})),GS(this,"twotouchdown",(e=>{jS(this,_S,!0),this.x0=e._x,this.y0=e._y;const t=new Me(e._x,e._y),n=new Me(e._x1,e._y1);this.line0=new NS(t,n),this.midPoint=this.line0.getMidpoint()})),GS(this,"mousemove",(e=>{if(!HS(this,_S))return;const t=e._x-this.x0,n=e._y-this.y0,i=is(e),r=HS(this,YS).getLayerGroupByDivId(i.groupDivId),a=r.getActiveViewLayer(),o=a.getViewController(),s=a.displayToPlaneScale(t,n),l=o.getOffset3DFromPlaneOffset(s);r.addTranslation({x:l.getX(),y:l.getY(),z:l.getZ()}),r.draw(),this.x0=e._x,this.y0=e._y})),GS(this,"twotouchmove",(e=>{if(!HS(this,_S))return;const t=new Me(e._x,e._y),n=new Me(e._x1,e._y1),i=new NS(t,n).getLength()/this.line0.getLength(),r=is(e),a=HS(this,YS).getLayerGroupByDivId(r.groupDivId),o=a.getActiveViewLayer(),s=o.getViewController();if(1===i){const t=e._y-this.y0;if(Math.abs(t)<15)return;s.getImageSize().canScroll(2)&&(t>0?s.incrementIndex(2):s.decrementIndex(2))}else{const e=(i-1)/10;if(Math.abs(e)%.1<=.05){const t=o.displayToMainPlanePos(this.midPoint.getX(),this.midPoint.getY()),n=s.getPlanePositionFromPlanePoint(t);a.addScale(e,n),a.draw()}}})),GS(this,"mouseup",(e=>{HS(this,_S)&&jS(this,_S,!1)})),GS(this,"mouseout",(e=>{this.mouseup(e)})),GS(this,"touchstart",(e=>{const t=e.targetTouches;1===t.length?this.mousedown(e):2===t.length&&this.twotouchdown(e)})),GS(this,"touchmove",(e=>{const t=e.targetTouches;1===t.length?this.mousemove(e):2===t.length&&this.twotouchmove(e)})),GS(this,"touchend",(e=>{this.mouseup(e)})),GS(this,"wheel",(e=>{const t=-e.deltaY/500,n=is(e),i=HS(this,YS).getLayerGroupByDivId(n.groupDivId),r=i.getActiveViewLayer(),a=r.getViewController(),o=r.displayToMainPlanePos(e._x,e._y),s=a.getPlanePositionFromPlanePoint(o);i.addScale(t,s),i.draw()})),GS(this,"keydown",(e=>{e.context="ZoomAndPan",HS(this,YS).onKeydown(e)})),jS(this,YS,e)}activate(e){}init(){}},Opacity:class{constructor(e){KS(this,tg,{writable:!0,value:void 0}),KS(this,ng,{writable:!0,value:!1}),KS(this,ig,{writable:!0,value:void 0}),ZS(this,"mousedown",(e=>{$S(this,ng,!0),this.x0=e._x,this.y0=e._y})),ZS(this,"mousemove",(e=>{if(!JS(this,ng))return;const t=e._x-this.x0;if(Math.abs(t)>15){const n=is(e),i=JS(this,tg).getLayerGroupByDivId(n.groupDivId).getActiveViewLayer(),r=i.getOpacity();i.setOpacity(r+t/200),i.draw(),this.x0=e._x}})),ZS(this,"mouseup",(e=>{JS(this,ng)&&$S(this,ng,!1)})),ZS(this,"mouseout",(e=>{this.mouseup(e)})),ZS(this,"touchstart",(e=>{this.mousedown(e)})),ZS(this,"touchmove",(e=>{this.mousemove(e)})),ZS(this,"touchend",(e=>{this.mouseup(e)})),ZS(this,"wheel",(e=>{JS(this,ig).wheel(e)})),ZS(this,"keydown",(e=>{e.context="Opacity",JS(this,tg).onKeydown(e)})),$S(this,tg,e),$S(this,ig,new sS(e))}activate(e){}init(){}},Draw:class{constructor(e){kg(this,pp),kg(this,gp),kg(this,Sp),kg(this,dp),kg(this,hp),kg(this,up),kg(this,cp),Ng(this,jg,{writable:!0,value:void 0}),Ng(this,Xg,{writable:!0,value:void 0}),Ng(this,Yg,{writable:!0,value:void 0}),Ng(this,_g,{writable:!0,value:void 0}),Ng(this,Zg,{writable:!0,value:void 0}),Ng(this,Kg,{writable:!0,value:!1}),Ng(this,Jg,{writable:!0,value:null}),Ng(this,$g,{writable:!0,value:null}),Ng(this,ep,{writable:!0,value:null}),Ng(this,tp,{writable:!0,value:null}),Ng(this,np,{writable:!0,value:void 0}),Ng(this,ip,{writable:!0,value:[]}),Ng(this,rp,{writable:!0,value:null}),Ng(this,ap,{writable:!0,value:void 0}),Ng(this,op,{writable:!0,value:void 0}),Ng(this,sp,{writable:!0,value:"pointer"}),Ng(this,lp,{writable:!0,value:{}}),Bg(this,"mousedown",(e=>{if(Gg(this,Kg))return;const t=is(e),n=Gg(this,jg).getLayerGroupByDivId(t.groupDivId),i=n.getActiveDrawLayer().getKonvaStage(),r=i.getIntersection({x:e._x,y:e._y});if(Gg(this,Zg).setZoomScale(i.scale()),r){const e=r.getParent().find(".shape")[0];if(e&&e!==Gg(this,Yg).getShape()){Gg(this,Yg).disable(),Gg(this,Yg).setShape(e);const t=n.getActiveViewLayer().getViewController();Gg(this,Yg).setViewController(t),Gg(this,Yg).enable()}}else{Gg(this,Yg).disable(),Gg(this,Yg).setShape(null),Gg(this,Yg).setViewController(null),zg(this,Kg,!0),zg(this,$g,new(Gg(this,Jg)[Gg(this,np)])),zg(this,ip,[]);const t=n.getActiveViewLayer().displayToPlanePos(e._x,e._y);zg(this,rp,new Me(t.x,t.y)),Gg(this,ip).push(Gg(this,rp))}})),Bg(this,"mousemove",(e=>{if(!Gg(this,Kg))return;const t=is(e),n=Gg(this,jg).getLayerGroupByDivId(t.groupDivId),i=n.getActiveViewLayer().displayToPlanePos(e._x,e._y);(Math.abs(i.x-Gg(this,rp).getX())>0||Math.abs(i.y-Gg(this,rp).getY())>0)&&(1!==Gg(this,ip).length&&void 0!==Gg(this,ip)[Gg(this,ip).length-1].tmp&&Gg(this,ip).pop(),zg(this,rp,new Me(i.x,i.y)),Gg(this,rp).tmp=!0,Gg(this,ip).push(Gg(this,rp)),Vg(this,cp,mp).call(this,Gg(this,ip),n))})),Bg(this,"mouseup",(e=>{if(Gg(this,Kg))if(0!==Gg(this,ip).length)if(Gg(this,ip).length===Gg(this,$g).getNPoints()){const t=is(e),n=Gg(this,jg).getLayerGroupByDivId(t.groupDivId);Vg(this,up,yp).call(this,Gg(this,ip),n),zg(this,Kg,!1)}else void 0!==Gg(this,ip)[Gg(this,ip).length-1].tmp&&delete Gg(this,ip)[Gg(this,ip).length-1].tmp;else re.warn("Draw mouseup but no points...")})),Bg(this,"dblclick",(e=>{if(void 0!==Gg(this,$g).getNPoints())return;if(!Gg(this,Kg))return;if(0===Gg(this,ip).length)return void re.warn("Draw dblclick but no points...");const t=is(e),n=Gg(this,jg).getLayerGroupByDivId(t.groupDivId);Vg(this,up,yp).call(this,Gg(this,ip),n),zg(this,Kg,!1)})),Bg(this,"mouseout",(e=>{this.mouseup(e)})),Bg(this,"touchstart",(e=>{this.mousedown(e)})),Bg(this,"touchmove",(e=>{if(!Gg(this,Kg))return;const t=is(e),n=Gg(this,jg).getLayerGroupByDivId(t.groupDivId),i=n.getActiveViewLayer().displayToPlanePos(e._x,e._y);(Math.abs(i.x-Gg(this,rp).getX())>0||Math.abs(i.y-Gg(this,rp).getY())>0)&&(1!==Gg(this,ip).length&&Gg(this,ip).pop(),zg(this,rp,new Me(i.x,i.y)),Gg(this,ip).push(Gg(this,rp)),Gg(this,ip).length<Gg(this,$g).getNPoints()&&(clearTimeout(this.timer),this.timer=setTimeout((()=>{Gg(this,ip).push(Gg(this,rp))}),Gg(this,$g).getTimeout())),Vg(this,cp,mp).call(this,Gg(this,ip),n))})),Bg(this,"touchend",(e=>{this.dblclick(e)})),Bg(this,"wheel",(e=>{Gg(this,Xg).wheel(e)})),Bg(this,"keydown",(e=>{let t;if(Gg(this,Kg)||(e.context="Draw",Gg(this,jg).onKeydown(e)),("Delete"===e.key||"Backspace"===e.key)&&Gg(this,Yg).isActive()){const e=Gg(this,Yg).getShape().getParent();t=e.getLayer();const n=Ga(e.getChildren(vo)[0]),i=new go(e,n,t);i.onExecute=Gg(this,fp),i.onUndo=Gg(this,fp),i.execute(),Gg(this,jg).addToUndoStack(i)}"Escape"===e.key&&null!==Gg(this,tp)&&(t=Gg(this,tp).getLayer(),Gg(this,tp).destroy(),zg(this,tp,null),zg(this,Kg,!1),zg(this,ip,[]),t.draw())})),Ng(this,fp,{writable:!0,value:e=>{if(void 0!==Gg(this,lp)[e.type])for(let t=0;t<Gg(this,lp)[e.type].length;++t)Gg(this,lp)[e.type][t](e)}}),zg(this,jg,e),zg(this,Xg,new sS(e)),zg(this,Yg,new xg(e)),Gg(this,Yg).setDrawEventCallback(Gg(this,fp)),zg(this,Zg,e.getStyle()),zg(this,_g,new(Ta().Group));const t=new(Ta().Line)({points:[-10,-10,10,10],stroke:"red"}),n=new(Ta().Line)({points:[10,-10,-10,10],stroke:"red"});Gg(this,_g).width(20),Gg(this,_g).height(20),Gg(this,_g).add(t),Gg(this,_g).add(n)}activate(e){Gg(this,Yg).disable(),Gg(this,Yg).setShape(null),Gg(this,Yg).setViewController(null);const t=Gg(this,jg).getActiveLayerGroup();Vg(this,dp,Dp).call(this,e,t),e?(zg(this,op,document.body.style.cursor),Gg(this,jg).addEventListener("positionchange",(()=>{Vg(this,hp,vp).call(this,t)})),this.setFeatures({lineColour:Gg(this,Zg).getLineColour()})):(Vg(this,pp,Tp).call(this),zg(this,op,void 0),Gg(this,jg).removeEventListener("positionchange",(()=>{Vg(this,hp,vp).call(this,t)})))}setShapeOn(e,t){const n=()=>{document.body.style.cursor=Gg(this,sp),e.opacity(.75)};e.on("mouseover",(()=>{zg(this,ap,e),n()})),e.on("mouseout",(()=>{Vg(this,pp,Tp).call(this),zg(this,ap,void 0)}));const i=t.getActiveDrawLayer().getKonvaLayer();e.draggable(!0);let r={x:e.x(),y:e.y()};const a=Ga(e.getChildren(vo)[0]);let o=null;e.on("dragstart.draw",(()=>{o=e.getChildren(vo)[0].stroke();const n=t.getActiveDrawLayer().getKonvaStage(),r=n.scale(),a={x:1/r.x,y:1/r.y};Gg(this,_g).x(n.offset().x+n.width()/(2*r.x)),Gg(this,_g).y(n.offset().y+n.height()/(15*r.y)),Gg(this,_g).scale(a),i.add(Gg(this,_g)),Gg(this,Yg).setAnchorsActive(!1),i.draw()})),e.on("dragmove.draw",(n=>{const r=n.target;let a;!function(e,t){const n=t.getChildren(vo)[0],i=function(e){const t=e.find(".anchor");if(0===t.length)return;let n=t[0].x(),i=t[0].y();for(let e=0;e<t.length;++e)n=Math.min(n,t[e].x()),i=Math.min(i,t[e].y());return{x:n,y:i}}(t);if(void 0===i)return null;Ip(t,{x:-i.x,y:-i.y},{x:e.x-(i.x+Math.abs(n.width())),y:e.y-(i.y+Math.abs(n.height()))})}(t.getActiveDrawLayer().getBaseSize(),r);const s=Object.keys(Gg(this,Jg));for(let t=0;t<s.length&&(a=new(Gg(this,Jg)[s[t]]),!a.isFactoryGroup(e));++t);if(void 0===a)throw new Error("Cannot find factory to update quantification.");if(void 0!==a.updateQuantification){const e=t.getActiveViewLayer().getViewController();a.updateQuantification(r,e)}const l=qr(n.evt)[0],c=Vg(this,gp,Cp).call(this,l,t),u=Gg(this,_g).width()*Gg(this,_g).scaleX()/2,h=Gg(this,_g).height()*Gg(this,_g).scaleY()/2;Math.abs(c.x-Gg(this,_g).x())<u&&Math.abs(c.y-Gg(this,_g).y())<h?(Gg(this,_g).getChildren().forEach((function(e){e.stroke("orange")})),e.getChildren(Io).forEach((function(e){e.stroke("red")}))):(Gg(this,_g).getChildren().forEach((function(e){e.stroke("red")})),e.getChildren(Io).forEach((function(e){void 0!==e.stroke&&e.stroke(o)}))),i.draw()})),e.on("dragend.draw",(n=>{const s=n.target;if(Gg(this,_g).remove(),void 0===n||void 0===n.evt)return;const l=s.x(),c=s.y(),u=qr(n.evt)[0],h=Vg(this,gp,Cp).call(this,u,t),d=Gg(this,_g).width()*Gg(this,_g).scaleX()/2,S=Gg(this,_g).height()*Gg(this,_g).scaleY()/2;if(Math.abs(h.x-Gg(this,_g).x())<d&&Math.abs(h.y-Gg(this,_g).y())<S){s.x(r.x),s.y(r.y),Gg(this,Yg).disable(),Gg(this,Yg).setShape(null),Gg(this,Yg).setViewController(null),e.getChildren(Io).forEach((function(e){e.stroke(o)})),document.body.style.cursor=Gg(this,op);const t=new go(s,a,i);t.onExecute=Gg(this,fp),t.onUndo=Gg(this,fp),t.execute(),Gg(this,jg).addToUndoStack(t)}else{const e={x:l-r.x,y:c-r.y};if(0!==e.x||0!==e.y){const t=new eo(s,a,e,i);t.onExecute=Gg(this,fp),t.onUndo=Gg(this,fp),Gg(this,jg).addToUndoStack(t),Gg(this,fp).call(this,{type:"drawmove",id:s.id()})}Gg(this,Yg).setAnchorsActive(!0),Gg(this,Yg).resetAnchors()}i.draw(),r={x:s.x(),y:s.y()}})),e.on("dblclick",(e=>{const t=e.target,n=t.findOne("Label");if(void 0===n)throw new Error("Could not find the shape label.");const r=n.getText(),a=t.id(),o=e=>{r.meta=e,r.setText(Ct(r.meta.textExpr,r.meta.quantification)),n.setVisible(0!==r.meta.textExpr.length),Gg(this,fp).call(this,{type:"drawchange",id:a}),i.draw()};if(void 0!==Er.openRoiDialog)Er.openRoiDialog(r.meta,o);else{const e=Rr("Label",r.meta.textExpr);null!==e&&(r.meta.textExpr=e,o(r.meta))}}))}setOptions(e){zg(this,Jg,e),Gg(this,Yg).setFactoryList(e)}getOptionsType(){return"factory"}setFeatures(e){if(void 0!==e.shapeColour&&Gg(this,Zg).setLineColour(e.shapeColour),void 0!==e.shapeName){if(!this.hasShape(e.shapeName))throw new Error("Unknown shape: '"+e.shapeName+"'");zg(this,np,e.shapeName)}void 0!==e.mouseOverCursor&&zg(this,sp,e.mouseOverCursor)}init(){}getEventNames(){return["drawcreate","drawchange","drawmove","drawdelete","drawlabelchange"]}addEventListener(e,t){void 0===Gg(this,lp)[e]&&(Gg(this,lp)[e]=[]),Gg(this,lp)[e].push(t)}removeEventListener(e,t){if(void 0!==Gg(this,lp)[e])for(let n=0;n<Gg(this,lp)[e].length;++n)Gg(this,lp)[e][n]===t&&Gg(this,lp)[e].splice(n,1)}hasShape(e){return void 0!==Gg(this,Jg)[e]}},Filter:class{constructor(e){var t,n,i;Qm(this,Wm,{writable:!0,value:void 0}),Qm(this,Vm,{writable:!0,value:null}),Qm(this,Gm,{writable:!0,value:0}),Qm(this,zm,{writable:!0,value:new wn}),t=this,i=e=>{e.context="Filter",km(this,Wm).onKeydown(e)},(n=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(n="keydown"))in t?Object.defineProperty(t,n,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[n]=i,Qm(this,Hm,{writable:!0,value:e=>{km(this,zm).fireEvent(e)}}),Bm(this,Wm,e)}activate(e){for(const t in km(this,Vm))e?(km(this,Vm)[t].addEventListener("filterrun",km(this,Hm)),km(this,Vm)[t].addEventListener("filter-undo",km(this,Hm))):(km(this,Vm)[t].removeEventListener("filterrun",km(this,Hm)),km(this,Vm)[t].removeEventListener("filter-undo",km(this,Hm)))}setOptions(e){Bm(this,Vm,{});for(const t in e)km(this,Vm)[t]=new e[t](km(this,Wm))}getOptionsType(){return"instance"}init(){for(const e in km(this,Vm))km(this,Vm)[e].init()}getEventNames(){return["filterrun","filterundo"]}addEventListener(e,t){km(this,zm).add(e,t)}removeEventListener(e,t){km(this,zm).remove(e,t)}getSelectedFilter(){return km(this,Gm)}setFeatures(e){if(void 0!==e.filterName){if(!this.hasFilter(e.filterName))throw new Error("Unknown filter: '"+e.filterName+"'");km(this,Gm)&&km(this,Gm).activate(!1),Bm(this,Gm,km(this,Vm)[e.filterName]),km(this,Gm).activate(!0)}if(void 0!==e.run&&e.run){let t={};void 0!==e.runArgs&&(t=e.runArgs),this.getSelectedFilter().run(t)}}getFilterList(){return km(this,Vm)}hasFilter(e){return km(this,Vm)[e]}},Floodfill:class{constructor(e){Ep(this,sf),Ep(this,of),Mp(this,Np,{writable:!0,value:void 0}),Mp(this,Wp,{writable:!0,value:5}),Mp(this,Vp,{writable:!0,value:0}),Mp(this,Gp,{writable:!0,value:2e3}),Mp(this,zp,{writable:!0,value:null}),Mp(this,Hp,{writable:!0,value:null}),Mp(this,jp,{writable:!0,value:10}),Mp(this,Xp,{writable:!0,value:null}),Mp(this,Yp,{writable:!0,value:!1}),Mp(this,_p,{writable:!0,value:null}),Mp(this,Zp,{writable:!0,value:null}),Mp(this,Kp,{writable:!0,value:void 0}),Mp(this,Jp,{writable:!0,value:null}),Mp(this,$p,{writable:!0,value:[]}),Mp(this,ef,{writable:!0,value:!1}),Mp(this,tf,{writable:!0,value:void 0}),Mp(this,nf,{writable:!0,value:new ka}),Mp(this,rf,{writable:!0,value:new wn}),Mp(this,af,{writable:!0,value:e=>{const t=is(e),n=Qp(this,Np).getLayerGroupByDivId(t.groupDivId).getActiveViewLayer().displayToPlaneIndex(e._x,e._y);return{x:n.get(0),y:n.get(1)}}}),Rp(this,"mousedown",(e=>{const t=is(e),n=Qp(this,Np).getLayerGroupByDivId(t.groupDivId),i=n.getActiveViewLayer(),r=n.getActiveDrawLayer();kp(this,zp,i.getImageData()),Qp(this,zp)?(Qp(this,nf).setZoomScale(r.getKonvaLayer().getAbsoluteScale()),kp(this,Yp,!0),kp(this,Kp,Qp(this,af).call(this,e)),Up(this,sf,uf).call(this,Qp(this,Kp),Qp(this,jp),n),this.onThresholdChange(Qp(this,jp))):re.error("No image found")})),Rp(this,"mousemove",(e=>{if(!Qp(this,Yp))return;const t=Qp(this,af).call(this,e);kp(this,Xp,Math.round(Math.sqrt(Math.pow(Qp(this,Kp).x-t.x,2)+Math.pow(Qp(this,Kp).y-t.y,2))/2)),kp(this,Xp,Qp(this,Xp)<Qp(this,jp)?Qp(this,jp):Qp(this,Xp)-Qp(this,jp)),this.modifyThreshold(Qp(this,Xp))})),Rp(this,"mouseup",(e=>{kp(this,Yp,!1)})),Rp(this,"mouseout",(e=>{this.mouseup(e)})),Rp(this,"touchstart",(e=>{this.mousedown(e)})),Rp(this,"touchmove",(e=>{this.mousemove(e)})),Rp(this,"touchend",(e=>{this.mouseup(e)})),Rp(this,"keydown",(e=>{e.context="Floodfill",Qp(this,Np).onKeydown(e)})),Mp(this,lf,{writable:!0,value:e=>{Qp(this,rf).fireEvent(e)}}),kp(this,Np,e)}setExtend(e){kp(this,ef,e)}getExtend(){return Qp(this,ef)}extend(e,t,n){if(!Qp(this,Kp))throw"'initialpoint' not found. User must click before use extend!";Qp(this,Zp)&&Qp(this,Zp).destroy();const i=n.getActiveViewLayer().getViewController(),r=i.getCurrentIndex(),a=i.getImageSize(),o=Qp(this,Xp)||Qp(this,jp);for(let e=r.get(2),s=t||a.get(2);e<s&&Up(this,sf,uf).call(this,Qp(this,Kp),o,n);e++)i.incrementIndex(2);i.setCurrentPosition(r);for(let t=r.get(2),a=e||0;t>a&&Up(this,sf,uf).call(this,Qp(this,Kp),o,n);t--)i.decrementIndex(2);i.setCurrentPosition(r)}modifyThreshold(e,t){if(t||!Qp(this,Zp))throw"No shape found";t=Qp(this,Zp).getChildren((function(e){return"shape"===e.name()}))[0],clearTimeout(Qp(this,tf)),kp(this,tf,setTimeout((()=>{if(kp(this,Jp,Up(this,of,cf).call(this,Qp(this,Kp),e,!0)),!Qp(this,Jp))return!1;const n=[];for(let e=0,t=Qp(this,Jp).length;e<t;++e)n.push(Qp(this,Jp)[e].x),n.push(Qp(this,Jp)[e].y);t.setPoints(n),t.getLayer().draw(),this.onThresholdChange(e)}),100))}onThresholdChange(e){}activate(e){e&&(Qp(this,nf).setBaseScale(Qp(this,Np).getBaseScale()),this.setFeatures({shapeColour:Qp(this,nf).getLineColour()}))}init(){}getEventNames(){return["drawcreate","drawchange","drawmove","drawdelete"]}addEventListener(e,t){Qp(this,rf).add(e,t)}removeEventListener(e,t){Qp(this,rf).remove(e,t)}setFeatures(e){void 0!==e.shapeColour&&Qp(this,nf).setLineColour(e.shapeColour)}},Livewire:class{constructor(e){mf(this,Qf),mf(this,qf),mf(this,Mf),yf(this,If,{writable:!0,value:void 0}),yf(this,Lf,{writable:!0,value:!1}),yf(this,bf,{writable:!0,value:null}),yf(this,Pf,{writable:!0,value:null}),yf(this,Af,{writable:!0,value:new ka}),yf(this,Of,{writable:!0,value:new hf}),yf(this,xf,{writable:!0,value:new hf}),yf(this,Ff,{writable:!0,value:[]}),yf(this,Rf,{writable:!0,value:5}),yf(this,Ef,{writable:!0,value:new wn}),yf(this,Uf,{writable:!0,value:new pf}),ff(this,"mousedown",(e=>{const t=is(e),n=wf(this,If).getLayerGroupByDivId(t.groupDivId),i=n.getActiveViewLayer(),r=i.getViewController().getImageSize(),a=i.displayToPlaneIndex(e._x,e._y);if(wf(this,Lf))if(Math.abs(a.get(0)-this.x0)<wf(this,Rf)&&Math.abs(a.get(1)-this.y0)<wf(this,Rf))Df(this,Qf,Wf).call(this);else{Cf(this,Of,wf(this,xf)),Df(this,Mf,Bf).call(this,r);const e={x:a.get(0),y:a.get(1)};wf(this,Uf).doTraining(e),wf(this,Of).addControlPoint(wf(this,xf).getPoint(0))}else{Cf(this,Lf,!0),this.x0=a.get(0),this.y0=a.get(1),Df(this,qf,Nf).call(this),Df(this,Mf,Bf).call(this,r),Cf(this,Pf,null);const e=n.getActiveDrawLayer();wf(this,Af).setZoomScale(e.getKonvaLayer().getAbsoluteScale());const t={x:a.get(0),y:a.get(1)};wf(this,Uf).doTraining(t);const i=new Me(a.get(0),a.get(1));wf(this,Of).addPoint(i),wf(this,Of).addControlPoint(i)}})),ff(this,"mousemove",(e=>{if(!wf(this,Lf))return;const t=is(e),n=wf(this,If).getLayerGroupByDivId(t.groupDivId),i=n.getActiveViewLayer().displayToPlaneIndex(e._x,e._y);let r={x:i.get(0),y:i.get(1)};wf(this,Uf).setPoint(r);let a=[],o=!1;for(;!wf(this,Ff)[r.y][r.x]&&!o;)if(a=wf(this,Uf).doWork(),0===a.length)o=!0;else for(let e=0;e<a.length-1;e+=2){const t=a[e],n=a[e+1];wf(this,Ff)[t.y][t.x]=n}for(Cf(this,xf,new hf),o=!1;r&&!o;)wf(this,xf).addPoint(new Me(r.x,r.y)),wf(this,Ff)[r.y]&&wf(this,Ff)[r.y][r.x]?r=wf(this,Ff)[r.y][r.x]:o=!0;wf(this,xf).appenPath(wf(this,Of)),wf(this,Pf)&&wf(this,Pf).destroy();const s=new Op;Cf(this,Pf,s.create(wf(this,xf).pointArray,wf(this,Af))),wf(this,Pf).id(sg());const l=n.getActiveDrawLayer();l.getDrawController().getCurrentPosGroup().add(wf(this,Pf)),Cf(this,bf,new _a(wf(this,Pf),"livewire",l.getKonvaLayer())),wf(this,bf).execute()})),ff(this,"mouseout",(e=>{this.mouseup(e)})),ff(this,"dblclick",(e=>{Df(this,Qf,Wf).call(this)})),ff(this,"touchstart",(e=>{this.mousedown(e)})),ff(this,"touchmove",(e=>{this.mousemove(e)})),ff(this,"touchend",(e=>{this.mouseup(e)})),ff(this,"keydown",(e=>{e.context="Livewire",wf(this,If).onKeydown(e)})),yf(this,kf,{writable:!0,value:e=>{wf(this,Ef).fireEvent(e)}}),Cf(this,If,e)}mouseup(e){}activate(e){if(e){const e=wf(this,If).getActiveLayerGroup().getActiveViewLayer(),t=e.getViewController().getImageSize();wf(this,Uf).setDimensions(t.get(0),t.get(1)),wf(this,Uf).setData(e.getImageData().data),wf(this,Af).setBaseScale(wf(this,If).getBaseScale()),this.setFeatures({shapeColour:wf(this,Af).getLineColour()})}}init(){}getEventNames(){return["drawcreate","drawchange","drawmove","drawdelete"]}addEventListener(e,t){wf(this,Ef).add(e,t)}removeEventListener(e,t){wf(this,Ef).remove(e,t)}setFeatures(e){void 0!==e.shapeColour&&wf(this,Af).setLineColour(e.shapeColour)}}},sy={draw:{ArrowFactory:class{getGroupName(){return"line-group"}getNPoints(){return 2}getTimeout(){return 0}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=new NS(e[0],e[1]),r=new(Ta().Line)({points:[i.getBegin().getX(),i.getBegin().getY(),i.getEnd().getX(),i.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),a=VS(i,e[0],t.scale(10)),o=VS(i,e[1],t.scale(10));r.hitFunc((function(e){e.beginPath(),e.moveTo(a.getBegin().getX(),a.getBegin().getY()),e.lineTo(a.getEnd().getX(),a.getEnd().getY()),e.lineTo(o.getEnd().getX(),o.getEnd().getY()),e.lineTo(o.getBegin().getX(),o.getBegin().getY()),e.closePath(),e.fillStrokeShape(r)}));const s=new Me(i.getBegin().getX(),i.getBegin().getY()-10),l=new NS(i.getBegin(),s),c=WS(i,l),u=c*Math.PI/180,h=5*t.getScaledStrokeWidth(),d=new(Ta().RegularPolygon)({x:i.getBegin().getX()+h*Math.sin(u),y:i.getBegin().getY()+h*Math.cos(u),sides:3,radius:h,rotation:-c,fill:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape-triangle"}),S=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"});let g="";g="",S.setText(""),S.meta={textExpr:"",quantification:{}};const p=i.getBegin().getX()>i.getEnd().getX()?0:-1,f=i.getBegin().getY()>i.getEnd().getY()?-1:0,m=new(Ta().Label)({x:i.getEnd().getX()+p*S.width(),y:i.getEnd().getY()+f*t.applyZoomScale(15).y,scale:t.applyZoomScale(1),visible:0!=="".length,name:"label"});m.add(S),m.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const y=new(Ta().Group);return y.name(this.getGroupName()),y.add(m),y.add(d),y.add(r),y.visible(!0),y}getAnchors(e,t){const n=e.points(),i=[];return i.push(pg(n[0]+e.x(),n[1]+e.y(),"begin",t)),i.push(pg(n[2]+e.x(),n[3]+e.y(),"end",t)),i}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"shape-triangle"===e.name()}))[0],o=i.getChildren((function(e){return"label"===e.name()}))[0],s=i.getChildren((function(e){return"begin"===e.id()}))[0],l=i.getChildren((function(e){return"end"===e.id()}))[0];switch(e.id()){case"begin":s.x(e.x()),s.y(e.y());break;case"end":l.x(e.x()),l.y(e.y())}const c=s.x()-r.x(),u=s.y()-r.y(),h=l.x()-r.x(),d=l.y()-r.y();r.points([c,u,h,d]);const S=new Me(s.x(),s.y()),g=new Me(l.x(),l.y()),p=new NS(S,g),f=new Me(c,u),m=new Me(h,d),y=VS(p,f,10),v=VS(p,m,10);r.hitFunc((function(e){e.beginPath(),e.moveTo(y.getBegin().getX(),y.getBegin().getY()),e.lineTo(y.getEnd().getX(),y.getEnd().getY()),e.lineTo(v.getEnd().getX(),v.getEnd().getY()),e.lineTo(v.getBegin().getX(),v.getBegin().getY()),e.closePath(),e.fillStrokeShape(r)}));const D=new Me(p.getBegin().getX(),p.getBegin().getY()-10),w=new NS(p.getBegin(),D),C=WS(p,w),T=C*Math.PI/180;a.x(p.getBegin().getX()+a.radius()*Math.sin(T)),a.y(p.getBegin().getY()+a.radius()*Math.cos(T)),a.rotation(-C);const I=o.getText();I.setText(I.meta.textExpr);const L=p.getBegin().getX()>p.getEnd().getX()?0:-1,b=p.getBegin().getY()>p.getEnd().getY()?-1:0,P={x:p.getEnd().getX()+L*I.width(),y:p.getEnd().getY()+b*t.applyZoomScale(15).y};o.position(P)}},CircleFactory:class{constructor(){_f(this,Jf),_f(this,Kf)}getGroupName(){return"circle-group"}getNPoints(){return 2}getTimeout(){return 0}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=Math.abs(e[0].getX()-e[1].getX()),r=Math.abs(e[0].getY()-e[1].getY()),a=Math.round(Math.sqrt(i*i+r*r)),o=new Yf(e[0],a),s=new(Ta().Circle)({x:o.getCenter().getX(),y:o.getCenter().getY(),radius:o.getRadius(),stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),l=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"});let c="";c="{surface}";const u=o.quantify(n,wt(c));l.setText(Ct(c,u)),l.meta={textExpr:c,quantification:u};const h=new(Ta().Label)({x:o.getCenter().getX(),y:o.getCenter().getY(),scale:t.applyZoomScale(1),visible:0!==c.length,name:"label"});h.add(l),h.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const d=new(Ta().Group);return d.name(this.getGroupName()),d.add(h),d.add(s),d.visible(!0),d}getAnchors(e,t){const n=e.x(),i=e.y(),r=e.radius(),a=[];return a.push(pg(n-r,i,"left",t)),a.push(pg(n+r,i,"right",t)),a.push(pg(n,i-r,"bottom",t)),a.push(pg(n,i+r,"top",t)),a}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"label"===e.name()}))[0],o=i.getChildren((function(e){return"left"===e.id()}))[0],s=i.getChildren((function(e){return"right"===e.id()}))[0],l=i.getChildren((function(e){return"bottom"===e.id()}))[0],c=i.getChildren((function(e){return"top"===e.id()}))[0];const u={x:r.x(),y:r.y()};let h;switch(e.id()){case"left":h=u.x-e.x(),o.y(s.y()),s.x(u.x+h),l.y(u.y-h),c.y(u.y+h);break;case"right":h=e.x()-u.x,s.y(o.y()),o.x(u.x-h),l.y(u.y-h),c.y(u.y+h);break;case"bottom":h=u.y-e.y(),l.x(c.x()),o.x(u.x-h),s.x(u.x+h),c.y(u.y+h);break;case"top":h=e.y()-u.y,c.x(l.x()),o.x(u.x-h),s.x(u.x+h),l.y(u.y-h);break;default:re.error("Unhandled anchor id: "+e.id())}r.radius(Math.abs(h));const d=new Me(i.x()+u.x,i.y()+u.y),S=(new Yf(d,h),{x:u.x,y:u.y});a.position(S),Zf(this,Kf,$f).call(this,i,n)}updateQuantification(e,t){Zf(this,Kf,$f).call(this,e,t)}},EllipseFactory:class{constructor(){lm(this,hm),lm(this,um)}getGroupName(){return"ellipse-group"}getNPoints(){return 2}getTimeout(){return 0}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=Math.abs(e[0].getX()-e[1].getX()),r=Math.abs(e[0].getY()-e[1].getY()),a=new sm(e[0],i,r),o=new(Ta().Ellipse)({x:a.getCenter().getX(),y:a.getCenter().getY(),radius:{x:a.getA(),y:a.getB()},stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),s=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"});let l="";l="{surface}";const c=a.quantify(n,wt(l));s.setText(Ct(l,c)),s.meta={textExpr:l,quantification:c};const u=new(Ta().Label)({x:a.getCenter().getX(),y:a.getCenter().getY(),scale:t.applyZoomScale(1),visible:0!==l.length,name:"label"});u.add(s),u.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const h=new(Ta().Group);return h.name(this.getGroupName()),h.add(u),h.add(o),h.visible(!0),h}getAnchors(e,t){const n=e.x(),i=e.y(),r=e.radius(),a=[];return a.push(pg(n-r.x,i-r.y,"topLeft",t)),a.push(pg(n+r.x,i-r.y,"topRight",t)),a.push(pg(n+r.x,i+r.y,"bottomRight",t)),a.push(pg(n-r.x,i+r.y,"bottomLeft",t)),a}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"label"===e.name()}))[0],o=i.getChildren((function(e){return"topLeft"===e.id()}))[0],s=i.getChildren((function(e){return"topRight"===e.id()}))[0],l=i.getChildren((function(e){return"bottomRight"===e.id()}))[0],c=i.getChildren((function(e){return"bottomLeft"===e.id()}))[0];switch(e.id()){case"topLeft":o.x(e.x()),o.y(e.y()),s.y(e.y()),c.x(e.x());break;case"topRight":s.x(e.x()),s.y(e.y()),o.y(e.y()),l.x(e.x());break;case"bottomRight":l.x(e.x()),l.y(e.y()),c.y(e.y()),s.x(e.x());break;case"bottomLeft":c.x(e.x()),c.y(e.y()),l.y(e.y()),o.x(e.x());break;default:re.error("Unhandled anchor id: "+e.id())}const u=(s.x()-o.x())/2,h=(l.y()-s.y())/2,d={x:o.x()+u,y:s.y()+h};r.position(d);const S={x:Math.abs(u),y:Math.abs(h)};S&&r.radius(S);const g=new Me(i.x()+d.x,i.y()+d.y),p=(new sm(g,S.x,S.y),{x:d.x,y:d.y});a.position(p),cm(this,um,dm).call(this,i,n)}updateQuantification(e,t){cm(this,um,dm).call(this,e,t)}},FreeHandFactory:class{getGroupName(){return"freeHand-group"}getNPoints(){}getTimeout(){return 25}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=[];for(let t=0;t<e.length;++t)i.push(e[t].getX()),i.push(e[t].getY());const r=new(Ta().Line)({points:i,stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape",tension:.5}),a=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),name:"text"});let o="";o="",a.setText(""),a.meta={textExpr:"",quantification:{}};const s=new(Ta().Label)({x:e[0].getX(),y:e[0].getY()+t.scale(10),scale:t.applyZoomScale(1),visible:0!=="".length,name:"label"});s.add(a),s.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const l=new(Ta().Group);return l.name(this.getGroupName()),l.add(s),l.add(r),l.visible(!0),l}getAnchors(e,t){const n=e.points(),i=[];for(let r=0;r<n.length;r+=2){const a=n[r]+e.x(),o=n[r+1]+e.y(),s=r.toString();i.push(pg(a,o,s,t))}return i}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"label"===e.name()}))[0],o=i.getChildren((function(t){return t.id()===e.id()}))[0];o.x(e.x()),o.y(e.y());const s=r.points();s[e.id()]=e.x()-r.x(),s[e.id()+1]=e.y()-r.y(),r.points(s.concat());const l=a.getText();l.setText(l.meta.textExpr);const c={x:s[0]+r.x(),y:s[1]+r.y()+t.scale(10)};a.position(c)}},ProtractorFactory:class{getGroupName(){return"protractor-group"}getNPoints(){return 3}getTimeout(){return 500}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=new NS(e[0],e[1]),r=[];for(let t=0;t<e.length;++t)r.push(e[t].getX()),r.push(e[t].getY());const a=new(Ta().Line)({points:r,stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),o=new(Ta().Group);if(o.name(this.getGroupName()),3===e.length){const n=new NS(e[1],e[2]);a.hitFunc((function(t){t.beginPath(),t.moveTo(e[0].getX(),e[0].getY()),t.lineTo(e[1].getX(),e[1].getY()),t.lineTo(e[2].getX(),e[2].getY()),t.closePath(),t.fillStrokeShape(a)}));let r=WS(i,n),s=i.getInclination();r>180&&(r=360-r,s+=r);const l=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"});let c="";c="{angle}";const u={angle:{value:r,unit:ES("unit.degree")}};l.setText(Ct(c,u)),l.meta={textExpr:c,quantification:u};const h=(i.getMidpoint().getX()+n.getMidpoint().getX())/2,d=(i.getMidpoint().getY()+n.getMidpoint().getY())/2,S=new(Ta().Label)({x:h,y:d-t.applyZoomScale(15).y,scale:t.applyZoomScale(1),visible:0!==c.length,name:"label"});S.add(l),S.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const g=33*Math.min(i.getLength(),n.getLength())/100,p=new(Ta().Arc)({innerRadius:g,outerRadius:g,stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,angle:r,rotation:-s,x:e[1].getX(),y:e[1].getY(),name:"shape-arc"});o.add(S),o.add(p)}return o.add(a),o.visible(!0),o}getAnchors(e,t){const n=e.points(),i=[];return i.push(pg(n[0]+e.x(),n[1]+e.y(),"begin",t)),i.push(pg(n[2]+e.x(),n[3]+e.y(),"mid",t)),i.push(pg(n[4]+e.x(),n[5]+e.y(),"end",t)),i}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"label"===e.name()}))[0],o=i.getChildren((function(e){return"shape-arc"===e.name()}))[0],s=i.getChildren((function(e){return"begin"===e.id()}))[0],l=i.getChildren((function(e){return"mid"===e.id()}))[0],c=i.getChildren((function(e){return"end"===e.id()}))[0];switch(e.id()){case"begin":s.x(e.x()),s.y(e.y());break;case"mid":l.x(e.x()),l.y(e.y());break;case"end":c.x(e.x()),c.y(e.y())}const u=s.x()-r.x(),h=s.y()-r.y(),d=l.x()-r.x(),S=l.y()-r.y(),g=c.x()-r.x(),p=c.y()-r.y();r.points([u,h,d,S,g,p]),r.hitFunc((function(e){e.beginPath(),e.moveTo(u,h),e.lineTo(d,S),e.lineTo(g,p),e.closePath(),e.fillStrokeShape(r)}));const f=new Me(s.x(),s.y()),m=new Me(l.x(),l.y()),y=new Me(c.x(),c.y()),v=new NS(f,m),D=new NS(m,y);let w=WS(v,D),C=v.getInclination();w>180&&(w=360-w,C+=w);const T=a.getText(),I={angle:{value:w,unit:ES("unit.degree")}};T.setText(Ct(T.meta.textExpr,I)),T.meta.quantification=I;const L={x:(v.getMidpoint().getX()+D.getMidpoint().getX())/2,y:(v.getMidpoint().getY()+D.getMidpoint().getY())/2-t.applyZoomScale(15).y};a.position(L);const b=33*Math.min(v.getLength(),D.getLength())/100;o.innerRadius(b),o.outerRadius(b),o.angle(w),o.rotation(-C);const P={x:l.x(),y:l.y()};o.position(P)}},RectangleFactory:class{constructor(){Dm(this,Tm),Dm(this,Cm)}getGroupName(){return"rectangle-group"}getNPoints(){return 2}getTimeout(){return 0}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=new vm(e[0],e[1]),r=new(Ta().Rect)({x:i.getBegin().getX(),y:i.getBegin().getY(),width:i.getWidth(),height:i.getHeight(),stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),a=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"});let o="";o="{surface}";const s=i.quantify(n,wt(o));a.setText(Ct(o,s)),a.meta={textExpr:o,quantification:s};const l=new(Ta().Label)({x:i.getBegin().getX(),y:i.getEnd().getY(),scale:t.applyZoomScale(1),visible:0!==o.length,name:"label"});l.add(a),l.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const c=new(Ta().Group);return c.name(this.getGroupName()),c.add(l),c.add(r),c.visible(!0),c}getAnchors(e,t){const n=e.x(),i=e.y(),r=e.width(),a=e.height(),o=[];return o.push(pg(n,i,"topLeft",t)),o.push(pg(n+r,i,"topRight",t)),o.push(pg(n+r,i+a,"bottomRight",t)),o.push(pg(n,i+a,"bottomLeft",t)),o}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"label"===e.name()}))[0],o=i.getChildren((function(e){return"topLeft"===e.id()}))[0],s=i.getChildren((function(e){return"topRight"===e.id()}))[0],l=i.getChildren((function(e){return"bottomRight"===e.id()}))[0],c=i.getChildren((function(e){return"bottomLeft"===e.id()}))[0];let u;switch(e.id()){case"topLeft":o.x(e.x()),o.y(e.y()),s.y(e.y()),c.x(e.x());break;case"topRight":s.x(e.x()),s.y(e.y()),o.y(e.y()),l.x(e.x());break;case"bottomRight":l.x(e.x()),l.y(e.y()),c.y(e.y()),s.x(e.x());break;case"bottomLeft":c.x(e.x()),c.y(e.y()),l.y(e.y()),o.x(e.x());break;default:re.error("Unhandled anchor id: "+e.id())}r.position(o.position());const h=s.x()-o.x(),d=c.y()-o.y();h&&d&&r.size({width:h,height:d});const S=new Me(i.x()+o.x(),i.y()+o.y()),g=new Me(i.x()+l.x(),i.y()+l.y()),p=new vm(S,g);const f={x:p.getBegin().getX()-i.x(),y:p.getEnd().getY()-i.y()};a.position(f),wm(this,Cm,Im).call(this,i,n)}updateQuantification(e,t){wm(this,Cm,Im).call(this,e,t)}},RoiFactory:Op,RulerFactory:class{getGroupName(){return"ruler-group"}getNPoints(){return 2}getTimeout(){return 0}isFactoryGroup(e){return this.getGroupName()===e.name()}create(e,t,n){const i=new NS(e[0],e[1]),r=new(Ta().Line)({points:[i.getBegin().getX(),i.getBegin().getY(),i.getEnd().getX(),i.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape"}),a=t.scale(10),o=VS(i,e[0],a),s=new(Ta().Line)({points:[o.getBegin().getX(),o.getBegin().getY(),o.getEnd().getX(),o.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape-tick0"}),l=VS(i,e[1],a),c=new(Ta().Line)({points:[l.getBegin().getX(),l.getBegin().getY(),l.getEnd().getX(),l.getEnd().getY()],stroke:t.getLineColour(),strokeWidth:t.getStrokeWidth(),strokeScaleEnabled:!1,name:"shape-tick1"});r.hitFunc((function(e){e.beginPath(),e.moveTo(o.getBegin().getX(),o.getBegin().getY()),e.lineTo(o.getEnd().getX(),o.getEnd().getY()),e.lineTo(l.getEnd().getX(),l.getEnd().getY()),e.lineTo(l.getBegin().getX(),l.getBegin().getY()),e.closePath(),e.fillStrokeShape(r)}));const u=new(Ta().Text)({fontSize:t.getFontSize(),fontFamily:t.getFontFamily(),fill:t.getLineColour(),padding:t.getTextPadding(),shadowColor:t.getShadowLineColour(),shadowOffset:t.getShadowOffset(),name:"text"});let h="";h="{length}";const d=i.quantify(n);u.setText(Ct(h,d)),u.meta={textExpr:h,quantification:d};const S=i.getBegin().getX()>i.getEnd().getX()?0:-1,g=i.getBegin().getY()>i.getEnd().getY()?-1:0,p=new(Ta().Label)({x:i.getEnd().getX()+S*u.width(),y:i.getEnd().getY()+g*t.applyZoomScale(15).y,scale:t.applyZoomScale(1),visible:0!==h.length,name:"label"});p.add(u),p.add(new(Ta().Tag)({fill:t.getLineColour(),opacity:t.getTagOpacity()}));const f=new(Ta().Group);return f.name(this.getGroupName()),f.add(p),f.add(s),f.add(c),f.add(r),f.visible(!0),f}getAnchors(e,t){const n=e.points(),i=[];return i.push(pg(n[0]+e.x(),n[1]+e.y(),"begin",t)),i.push(pg(n[2]+e.x(),n[3]+e.y(),"end",t)),i}update(e,t,n){const i=e.getParent(),r=i.getChildren((function(e){return"shape"===e.name()}))[0],a=i.getChildren((function(e){return"shape-tick0"===e.name()}))[0],o=i.getChildren((function(e){return"shape-tick1"===e.name()}))[0],s=i.getChildren((function(e){return"label"===e.name()}))[0],l=i.getChildren((function(e){return"begin"===e.id()}))[0],c=i.getChildren((function(e){return"end"===e.id()}))[0];switch(e.id()){case"begin":l.x(e.x()),l.y(e.y());break;case"end":c.x(e.x()),c.y(e.y())}const u=l.x()-r.x(),h=l.y()-r.y(),d=c.x()-r.x(),S=c.y()-r.y();r.points([u,h,d,S]);const g=new Me(l.x(),l.y()),p=new Me(c.x(),c.y()),f=new NS(g,p),m=new Me(u,h),y=new Me(d,S),v=VS(f,m,t.scale(10));a.points([v.getBegin().getX(),v.getBegin().getY(),v.getEnd().getX(),v.getEnd().getY()]);const D=VS(f,y,t.scale(10));o.points([D.getBegin().getX(),D.getBegin().getY(),D.getEnd().getX(),D.getEnd().getY()]),r.hitFunc((function(e){e.beginPath(),e.moveTo(v.getBegin().getX(),v.getBegin().getY()),e.lineTo(v.getEnd().getX(),v.getEnd().getY()),e.lineTo(D.getEnd().getX(),D.getEnd().getY()),e.lineTo(D.getBegin().getX(),D.getBegin().getY()),e.closePath(),e.fillStrokeShape(r)}));const w=s.getText(),C=f.quantify(n);w.setText(Ct(w.meta.textExpr,C)),w.meta.quantification=C;const T=f.getBegin().getX()>f.getEnd().getX()?0:-1,I=f.getBegin().getY()>f.getEnd().getY()?-1:0,L={x:f.getEnd().getX()+T*w.width(),y:f.getEnd().getY()+I*t.applyZoomScale(15).y};s.position(L)}}},filter:{Threshold:class{constructor(e){Qm(this,jm,{writable:!0,value:void 0}),Qm(this,Xm,{writable:!0,value:new Rm}),Qm(this,Ym,{writable:!0,value:!0}),Qm(this,_m,{writable:!0,value:new wn}),Qm(this,Zm,{writable:!0,value:e=>{km(this,_m).fireEvent(e)}}),Bm(this,jm,e)}activate(e){e&&Bm(this,Ym,!0)}init(){}run(e){km(this,Xm).setMin(e.min),km(this,Xm).setMax(e.max),km(this,Ym)&&(km(this,Xm).setOriginalImage(km(this,jm).getLastImage()),Bm(this,Ym,!1));const t=new ay(km(this,Xm),km(this,jm));t.onExecute=km(this,Zm),t.onUndo=km(this,Zm),t.execute(),km(this,jm).addToUndoStack(t)}addEventListener(e,t){km(this,_m).add(e,t)}removeEventListener(e,t){km(this,_m).remove(e,t)}},Sobel:class{constructor(e){Qm(this,ey,{writable:!0,value:void 0}),Qm(this,ty,{writable:!0,value:new wn}),Qm(this,ny,{writable:!0,value:e=>{km(this,ty).fireEvent(e)}}),Bm(this,ey,e)}activate(e){}init(){}run(e){const t=new Um;t.setOriginalImage(km(this,ey).getLastImage());const n=new ay(t,km(this,ey));n.onExecute=km(this,ny),n.onUndo=km(this,ny),n.execute(),km(this,ey).addToUndoStack(n)}addEventListener(e,t){km(this,ty).add(e,t)}removeEventListener(e,t){km(this,ty).remove(e,t)}},Sharpen:class{constructor(e){Qm(this,Km,{writable:!0,value:void 0}),Qm(this,Jm,{writable:!0,value:new wn}),Qm(this,$m,{writable:!0,value:e=>{km(this,Jm).fireEvent(e)}}),Bm(this,Km,e)}activate(e){}init(){}run(e){const t=new Mm;t.setOriginalImage(km(this,Km).getLastImage());const n=new ay(t,km(this,Km));n.onExecute=km(this,$m),n.onUndo=km(this,$m),n.execute(),km(this,Km).addToUndoStack(n)}addEventListener(e,t){km(this,Jm).add(e,t)}removeEventListener(e,t){km(this,Jm).remove(e,t)}}}};function ly(e,t){hy(e,t),t.add(e)}function cy(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,"string");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function uy(e,t,n){hy(e,t),t.set(e,n)}function hy(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function dy(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function Sy(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,py(e,t,"set"),n),n}function gy(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,py(e,t,"get"))}function py(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var fy=new WeakMap,my=new WeakMap,yy=new WeakMap,vy=new WeakMap,Dy=new WeakMap,wy=new WeakMap,Cy=new WeakMap,Ty=new WeakMap,Iy=new WeakSet,Ly=new WeakSet,by=new WeakMap,Py=new WeakMap,Ay=new WeakMap,Oy=new WeakMap,xy=new WeakMap,Fy=new WeakMap,Ry=new WeakMap,Ey=new WeakMap,My=new WeakSet,qy=new WeakSet,Uy=new WeakSet;class Qy{constructor(){ly(this,Uy),ly(this,qy),ly(this,My),ly(this,Ly),ly(this,Iy),uy(this,fy,{writable:!0,value:null}),uy(this,my,{writable:!0,value:null}),uy(this,yy,{writable:!0,value:null}),uy(this,vy,{writable:!0,value:null}),uy(this,Dy,{writable:!0,value:null}),uy(this,wy,{writable:!0,value:null}),uy(this,Cy,{writable:!0,value:new ka}),uy(this,Ty,{writable:!0,value:new wn}),cy(this,"addToUndoStack",(e=>{null!==gy(this,wy)&&gy(this,wy).add(e)})),cy(this,"loadFiles",(e=>{0!==e.length?gy(this,vy).loadFiles(e):re.warn("Ignoring empty input file list.")})),cy(this,"loadURLs",((e,t)=>{0!==e.length?gy(this,vy).loadURLs(e,t):re.warn("Ignoring empty input url list.")})),cy(this,"loadImageObject",(e=>{gy(this,vy).loadImageObject(e)})),cy(this,"onResize",(e=>{this.fitToContainer()})),cy(this,"onKeydown",(e=>{gy(this,by).call(this,e)})),cy(this,"defaultOnKeydown",(e=>{if(e.ctrlKey)if(e.shiftKey){const t=gy(this,Dy).getActiveLayerGroup().getActiveViewLayer().getViewController(),n=t.getImageSize();"ArrowLeft"===e.key?n.moreThanOne(3)&&t.decrementIndex(3):"ArrowUp"===e.key?t.canScroll()&&t.incrementScrollIndex():"ArrowRight"===e.key?n.moreThanOne(3)&&t.incrementIndex(3):"ArrowDown"===e.key&&t.canScroll()&&t.decrementScrollIndex()}else if("y"===e.key)gy(this,wy).redo();else if("z"===e.key)gy(this,wy).undo();else if(" "===e.key)for(let e=0;e<gy(this,Dy).getNumberOfLayerGroups();++e)gy(this,Dy).getLayerGroup(e).setShowCrosshair(!gy(this,Dy).getLayerGroup(e).getShowCrosshair())})),uy(this,by,{writable:!0,value:e=>{gy(this,Ty).fireEvent(e)}}),uy(this,Py,{writable:!0,value:e=>{e.type="loadstart",gy(this,by).call(this,e)}}),uy(this,Ay,{writable:!0,value:e=>{e.type="loadprogress",gy(this,by).call(this,e)}}),uy(this,Oy,{writable:!0,value:e=>{void 0===e.data&&re.error("Missing loaditem event data."),void 0===e.loadtype&&re.error("Missing loaditem event load type.");const t=e.isfirstitem;let n=null;if("image"===e.loadtype)t?gy(this,my).addNew(e.loadid,e.data.image,e.data.info):gy(this,my).update(e.loadid,e.data.image,e.data.info),n=e.data.info;else if("state"===e.loadtype){const t=new nl;t.apply(this,t.fromJSON(e.data)),n="state"}gy(this,by).call(this,{type:"loaditem",data:n,source:e.source,loadtype:e.loadtype,loadid:e.loadid,isfirstitem:e.isfirstitem}),"image"===e.loadtype&&0!==dy(this,Iy,ky).call(this,e.loadid).length&&t&&gy(this,fy).viewOnFirstLoadItem&&this.render(e.loadid)}}),uy(this,xy,{writable:!0,value:e=>{e.type="load",gy(this,by).call(this,e)}}),uy(this,Fy,{writable:!0,value:e=>{e.type="loadend",gy(this,by).call(this,e)}}),uy(this,Ry,{writable:!0,value:e=>{e.type="loaderror",gy(this,by).call(this,e)}}),uy(this,Ey,{writable:!0,value:e=>{e.type="loadabort",gy(this,by).call(this,e)}})}getImage(e){return gy(this,my).get(e).image}getLastImage(){return gy(this,my).get(gy(this,my).length()-1).image}setImage(e,t){gy(this,my).setImage(e,t)}setLastImage(e){gy(this,my).setImage(gy(this,my).length()-1,e)}addNewImage(e,t){const n=gy(this,my).length();return gy(this,by).call(this,{type:"loadstart",loadtype:"image",source:"internal",loadid:n}),gy(this,my).addNew(n,e,t),gy(this,by).call(this,{type:"loaditem",loadtype:"image",data:t,source:"internal",loadid:n,isfirstitem:!0}),gy(this,fy).viewOnFirstLoadItem&&this.render(n),gy(this,by).call(this,{type:"load",loadtype:"image",source:"internal",loadid:n}),gy(this,by).call(this,{type:"loadend",loadtype:"image",source:"internal",loadid:n}),n}getMetaData(e){return gy(this,my).get(e).meta}getMetaDataWithNames(e){let t=this.getMetaData(e);return void 0!==t["00020010"]&&(t=Object.keys(t).reduce(((e,n)=>{const i=$e(n);let r=i.getNameFromDictionary();return void 0===r&&(r="x"+i.getKey()),e[r]=t[n],e}),{})),t}getNumberOfLoadedData(){return gy(this,my).length()}canScroll(){return gy(this,Dy).getActiveLayerGroup().getActiveViewLayer().getViewController().canScroll()}canWindowLevel(){return gy(this,Dy).getActiveLayerGroup().getActiveViewLayer().getViewController().canWindowLevel()}getAddedScale(){return gy(this,Dy).getActiveLayerGroup().getAddedScale()}getBaseScale(){return gy(this,Dy).getActiveLayerGroup().getBaseScale()}getOffset(){return gy(this,Dy).getActiveLayerGroup().getOffset()}getToolboxController(){return gy(this,yy)}getActiveLayerGroup(){return gy(this,Dy).getActiveLayerGroup()}getViewLayersByDataIndex(e){return gy(this,Dy).getViewLayersByDataIndex(e)}getDrawLayersByDataIndex(e){return gy(this,Dy).getDrawLayersByDataIndex(e)}getLayerGroupByDivId(e){return gy(this,Dy).getLayerGroupByDivId(e)}getNumberOfLayerGroups(){return gy(this,Dy).getNumberOfLayerGroups()}getStyle(){return gy(this,Cy)}init(e){if(Sy(this,fy,e),void 0===gy(this,fy).viewOnFirstLoadItem&&(gy(this,fy).viewOnFirstLoadItem=!0),Sy(this,wy,new Dl),gy(this,wy).addEventListener("undoadd",gy(this,by)),gy(this,wy).addEventListener("undo",gy(this,by)),gy(this,wy).addEventListener("redo",gy(this,by)),gy(this,fy).tools&&0!==gy(this,fy).tools.length){const e={},t=Object.keys(gy(this,fy).tools);for(let n=0;n<t.length;++n){const i=t[n];if(void 0!==oy[i]){if(e[i]=new oy[i](this),void 0!==e[i].addEventListener){const t=e[i].getEventNames();for(let n=0;n<t.length;++n)e[i].addEventListener(t[n],gy(this,by))}const t=gy(this,fy).tools[i];if(void 0!==t.options){let n="raw";void 0!==e[i].getOptionsType&&(n=e[i].getOptionsType());let r=t.options;if("instance"===n||"factory"===n){r={};for(let e=0;e<t.options.length;++e){const a=t.options[e];let o=a;"factory"===n&&(o+="Factory");const s=i.charAt(0).toLowerCase()+i.slice(1);void 0!==sy[s][o]?r[a]=sy[s][o]:re.warn("Could not find option class for: "+a)}}e[i].setOptions(r)}}else re.warn("Could not initialise unknown tool: "+i)}Sy(this,yy,new Ml(e))}Sy(this,vy,new Ed(gy(this,fy).defaultCharacterSet)),gy(this,vy).onloadstart=gy(this,Py),gy(this,vy).onprogress=gy(this,Ay),gy(this,vy).onloaditem=gy(this,Oy),gy(this,vy).onload=gy(this,xy),gy(this,vy).onloadend=gy(this,Fy),gy(this,vy).onerror=gy(this,Ry),gy(this,vy).onabort=gy(this,Ey),Sy(this,my,new $d),Sy(this,Dy,new Hs),void 0!==gy(this,fy).binders&&gy(this,Dy).setBinders(gy(this,fy).binders)}reset(){gy(this,my).reset(),gy(this,Dy).empty(),gy(this,wy)&&(Sy(this,wy,new Dl),gy(this,wy).addEventListener("undoadd",gy(this,by)),gy(this,wy).addEventListener("undo",gy(this,by)),gy(this,wy).addEventListener("redo",gy(this,by)))}resetLayout(){gy(this,Dy).reset(),gy(this,Dy).draw()}addEventListener(e,t){gy(this,Ty).add(e,t)}removeEventListener(e,t){gy(this,Ty).remove(e,t)}abortLoad(){gy(this,vy).abort()}fitToContainer(){gy(this,Dy).syncLayerGroupScale()}initWLDisplay(){gy(this,Dy).getActiveLayerGroup().getActiveViewLayer().getViewController().initialise()}getDataViewConfig(){return gy(this,fy).dataViewConfigs}setDataViewConfig(e){gy(this,Dy).empty(),gy(this,fy).dataViewConfigs=e,dy(this,Ly,By).call(this,e)}setLayerGroupsBinders(e){const t=[];for(let n=0;n<e.length;++n)void 0!==Qs[e[n]]&&t.push(new Qs[e[n]]);gy(this,Dy).setBinders(t)}render(e){if(null==e)throw new Error("Cannot render without data index");0===gy(this,Dy).getNumberOfLayerGroups()&&dy(this,Ly,By).call(this,gy(this,fy).dataViewConfigs);const t=dy(this,Iy,ky).call(this,e);if(0!==t.length)for(let n=0;n<t.length;++n){const i=t[n],r=gy(this,Dy).getLayerGroupByDivId(i.divId);if(!r)throw new Error("No layer group for "+i.divId);0===r.getViewLayersByDataIndex(e).length&&(0===r.getNumberOfLayers()?dy(this,qy,Wy).call(this,e,i):dy(this,Uy,Vy).call(this,e,i)),r.draw()}else re.info("Not rendering data: "+e+" (no data view config)")}zoom(e,t,n){const i=gy(this,Dy).getActiveLayerGroup(),r=i.getActiveViewLayer().getViewController().getCurrentScrollPosition(),a=new ke(t,n,r);i.addScale(e,a),i.draw()}translate(e,t){const n=gy(this,Dy).getActiveLayerGroup();n.addTranslation({x:e,y:t}),n.draw()}setOpacity(e){const t=gy(this,Dy).getActiveLayerGroup().getActiveViewLayer();t.setOpacity(e),t.draw()}setDrawings(e,t){const n=gy(this,Dy).getActiveLayerGroup(),i=n.getActiveViewLayer().getViewController(),r=n.getActiveDrawLayer().getDrawController();r.setDrawings(e,t,gy(this,by),this.addToUndoStack),r.activateDrawLayer(i.getCurrentOrientedIndex(),i.getScrollIndex())}getState(){return(new nl).toJSON(this)}resetDisplay(){this.resetLayout(),this.initWLDisplay()}resetZoom(){this.resetLayout()}setColourMap(e){gy(this,Dy).getActiveLayerGroup().getActiveViewLayer().getViewController().setColourMapFromName(e)}setWindowLevelPreset(e){gy(this,Dy).getActiveLayerGroup().getActiveViewLayer().getViewController().setWindowLevelPreset(e)}setTool(e){for(let t=0;t<gy(this,Dy).getNumberOfLayerGroups();++t){const n=gy(this,Dy).getLayerGroup(t);let i=null;i="Draw"===e||"Livewire"===e||"Floodfill"===e?n.getActiveDrawLayer():n.getActiveViewLayer(),i&&gy(this,yy).bindLayer(i,n.getDivId())}gy(this,yy).setSelectedTool(e)}setToolFeatures(e){gy(this,yy).setToolFeatures(e)}undo(){gy(this,wy).undo()}redo(){gy(this,wy).redo()}getStackSize(){return gy(this,wy).getStackSize()}getCurrentStackIndex(){return gy(this,wy).getCurrentStackIndex()}}function ky(e){if(null===gy(this,fy).dataViewConfigs||void 0===gy(this,fy).dataViewConfigs)throw new Error("No available data view configuration");let t=[];return void 0!==gy(this,fy).dataViewConfigs["*"]?t=gy(this,fy).dataViewConfigs["*"]:void 0!==gy(this,fy).dataViewConfigs[e]&&(t=gy(this,fy).dataViewConfigs[e]),t}function By(e){const t=Object.keys(e),n=[];for(let i=0;i<t.length;++i){const r=e[t[i]];for(let e=0;e<r.length;++e){const t=r[e];if(!n.includes(t.divId)){const e=document.getElementById(t.divId),i=gy(this,Dy).addLayerGroup(e);dy(this,My,Ny).call(this,i),void 0!==t.orientation&&i.setTargetOrientation(Pe(t.orientation)),n.push(t.divId)}}}}function Ny(e){e.addEventListener("zoomchange",gy(this,by)),e.addEventListener("offsetchange",gy(this,by)),e.addEventListener("renderstart",gy(this,by)),e.addEventListener("renderend",gy(this,by));for(let t=0;t<Ri.length;++t)e.addEventListener(Ri[t],gy(this,by));gy(this,yy)&&gy(this,yy).hasTool("Draw")&&(e.addEventListener("drawcreate",gy(this,by)),e.addEventListener("drawdelete",gy(this,by)))}function Wy(e,t){dy(this,Uy,Vy).call(this,e,t),gy(this,yy)&&gy(this,yy).init()}function Vy(e,t){const n=gy(this,my).get(e);if(!n)throw new Error("Cannot initialise layer with data id: "+e);const i=gy(this,Dy).getLayerGroupByDivId(t.divId);if(!i)throw new Error("Cannot initialise layer with group id: "+t.divId);const r=n.image.getGeometry();gy(this,Dy).unbindLayerGroups();const a=(new Hi).create(n.meta,n.image),o=function(e,t){let n=Le();return void 0!==t&&(n=e.asOneAndZeros().getInverse().multiply(t)),n.getAbs()}(r.getOrientation(),i.getTargetOrientation());a.setOrientation(o),"SEG"===n.image.getMeta().Modality&&a.setAlphaFunction((function(e){return 0===e[0]&&0===e[1]&&0===e[2]?0:255})),void 0!==t.colourMap&&a.setColourMap(t.colourMap);const s=0===i.getNumberOfLayers();let l=1;s||(l=.5,void 0===t.colourMap&&a.setColourMap(ie.rainbow));const c=i.addViewLayer();c.setView(a,e);const u=r.getSize(o).get2D(),h=r.getSpacing(o).get2D();c.initialise(u,h,l);const d=c.getViewController();let S;"SEG"===n.image.getMeta().Modality&&(d.addEventListener("masksegmentdelete",gy(this,by)),d.addEventListener("masksegmentredraw",gy(this,by))),gy(this,my).addEventListener("imageset",c.onimageset),gy(this,my).addEventListener("imagechange",(e=>{c.onimagechange(e),this.render(e.dataid)})),gy(this,Dy).bindLayerGroups(),gy(this,yy)&&gy(this,yy).bindLayer(c,i.getDivId()),gy(this,yy)&&gy(this,yy).hasTool("Draw")&&(S=i.addDrawLayer(),S.initialise(u,h,e),S.setPlaneHelper(c.getViewController().getPlaneHelper()));const g=[d.getCurrentIndex().getValues(),d.getCurrentPosition().getValues()];i.updateLayersToPositionChange({value:g,srclayerid:c.getId()}),gy(this,Dy).syncLayerGroupScale();const p=r.getOrientation().getThirdColMajorDirection();c.setOffset(i.getOffset()),void 0!==t.orientation&&(2===p?"axial"!==t.orientation&&(c.addFlipOffsetY(),void 0!==S&&S.addFlipOffsetY()):0===p&&"sagittal"!==t.orientation&&(c.addFlipOffsetX(),void 0!==S&&S.addFlipOffsetX())),s?void 0!==t.orientation?0===p||2===p?i.flipScaleZ():(c.setScale(i.getScale()),void 0!==S&&S.setScale(i.getScale())):0===p?i.flipScaleZ():(c.setScale(i.getScale()),void 0!==S&&S.setScale(i.getScale())):(c.setScale(i.getScale()),void 0!==S&&S.setScale(i.getScale()))}function Gy(e,t,n){!function(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}(e,t),t.set(e,n)}function zy(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,jy(e,t,"get"))}function Hy(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,jy(e,t,"set"),n),n}function jy(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}var Xy=new WeakMap,Yy=new WeakMap;class _y{constructor(e,t){Gy(this,Xy,{writable:!0,value:!0}),Gy(this,Yy,{writable:!0,value:void 0}),void 0!==t&&Hy(this,Xy,t),Hy(this,Yy,new DataView(e))}writeUint8(e,t){return zy(this,Yy).setUint8(e,t),e+Uint8Array.BYTES_PER_ELEMENT}writeInt8(e,t){return zy(this,Yy).setInt8(e,t),e+Int8Array.BYTES_PER_ELEMENT}writeUint16(e,t){return zy(this,Yy).setUint16(e,t,zy(this,Xy)),e+Uint16Array.BYTES_PER_ELEMENT}writeInt16(e,t){return zy(this,Yy).setInt16(e,t,zy(this,Xy)),e+Int16Array.BYTES_PER_ELEMENT}writeUint32(e,t){return zy(this,Yy).setUint32(e,t,zy(this,Xy)),e+Uint32Array.BYTES_PER_ELEMENT}writeUint64(e,t){return zy(this,Yy).setBigUint64(e,t,zy(this,Xy)),e+BigUint64Array.BYTES_PER_ELEMENT}writeInt32(e,t){return zy(this,Yy).setInt32(e,t,zy(this,Xy)),e+Int32Array.BYTES_PER_ELEMENT}writeInt64(e,t){return zy(this,Yy).setBigInt64(e,t,zy(this,Xy)),e+BigInt64Array.BYTES_PER_ELEMENT}writeFloat32(e,t){return zy(this,Yy).setFloat32(e,t,zy(this,Xy)),e+Float32Array.BYTES_PER_ELEMENT}writeFloat64(e,t){return zy(this,Yy).setFloat64(e,t,zy(this,Xy)),e+Float64Array.BYTES_PER_ELEMENT}writeHex(e,t){const n=parseInt(t,16);return zy(this,Yy).setUint16(e,n,zy(this,Xy)),e+Uint16Array.BYTES_PER_ELEMENT}writeBinaryArray(e,t){if(t.length%8!=0)throw new Error("Cannot write boolean array as binary.");let n=null,i=null;for(let r=0,a=t.length;r<a;r+=8){n=0;for(let e=0;e<8;++e)i=0===t[r+e]?0:1,n+=i<<e;e=this.writeUint8(e,n)}return e}writeUint8Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeUint8(e,t[n]);return e}writeInt8Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeInt8(e,t[n]);return e}writeUint16Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeUint16(e,t[n]);return e}writeInt16Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeInt16(e,t[n]);return e}writeUint32Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeUint32(e,t[n]);return e}writeUint64Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeUint64(e,t[n]);return e}writeInt32Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeInt32(e,t[n]);return e}writeInt64Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeInt64(e,t[n]);return e}writeFloat32Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeFloat32(e,t[n]);return e}writeFloat64Array(e,t){for(let n=0,i=t.length;n<i;++n)e=this.writeFloat64(e,t[n]);return e}}function Zy(e,t){Jy(e,t),t.add(e)}function Ky(e,t,n){Jy(e,t),t.set(e,n)}function Jy(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function $y(e,t,n){if(!t.has(e))throw new TypeError("attempted to get private field on non-instance");return n}function ev(e,t){return function(e,t){return t.get?t.get.call(e):t.value}(e,nv(e,t,"get"))}function tv(e,t,n){return function(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}(e,nv(e,t,"set"),n),n}function nv(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}let iv=0;function rv(e){const t="1.2.826.0.1.3680043.9.7278.1.";let n="";if("ImplementationClassUID"===e)n=t+"0.32.0-beta.0";else{const i="."+(new Date).toISOString().replace(/\D/g,"").substring(0,14);iv+=1;const r="."+iv;n=t;const a=t.length+r.length+i.length,o=Math.min(e.length,64-a);if(o>1){let t="";for(let n=0;n<o;++n)t+=e.charCodeAt(n);n+=t.substring(0,o)}n+=i+r}return n}function av(e){return e%2==0}function ov(e){const t=He[e];return void 0!==t&&"string"===t}function sv(e,t){const n=new Uint8Array(e.length+1);return n.set(e),n.set(t,e.length),n}class lv{encode(e){const t=new Uint8Array(e.length);for(let n=0,i=e.length;n<i;++n)t[n]=e.charCodeAt(n);return t}}var cv=new WeakMap,uv=new WeakMap,hv=new WeakMap,dv=new WeakMap,Sv=new WeakMap,gv=new WeakMap,pv=new WeakSet,fv=new WeakSet,mv=new WeakSet,yv=new WeakSet,vv=new WeakSet,Dv=new WeakSet,wv=new WeakSet,Cv=new WeakSet;class Tv{constructor(){Zy(this,Cv),Zy(this,wv),Zy(this,Dv),Zy(this,vv),Zy(this,yv),Zy(this,mv),Zy(this,fv),Zy(this,pv),Ky(this,cv,{writable:!0,value:!1}),Ky(this,uv,{writable:!0,value:{copy:function(e){return e},remove:function(){return null},clear:function(e){return e.value=[],e},replace:function(e,t){return e.value=[t],e}}}),Ky(this,hv,{writable:!0,value:{default:{action:"copy",value:null}}}),Ky(this,dv,{writable:!0,value:ev(this,hv)}),Ky(this,Sv,{writable:!0,value:new lv}),Ky(this,gv,{writable:!0,value:ev(this,Sv)})}setUseUnVrForPrivateSq(e){tv(this,cv,e)}setRules(e){tv(this,dv,e)}useSpecialTextEncoder(){tv(this,gv,new TextEncoder)}useDefaultAnonymisationRules(){this.setRules({default:{action:"remove",value:null},PatientName:{action:"replace",value:"Anonymized"},"Meta Element":{action:"copy",value:null},Acquisition:{action:"copy",value:null},"Image Presentation":{action:"copy",value:null},Procedure:{action:"copy",value:null},"Pixel Data":{action:"copy",value:null}})}getBuffer(e){const t=e["00020010"].value[0],n=Vt(t),i=Gt(t);if(void 0!==e["00080005"]){const t=e["00080005"].value[0];void 0!==t&&"ISO-IR 6"!==t&&(re.debug("Change charset to UTF, was: "+t),this.useSpecialTextEncoder(),e["00080005"].value=["ISO_IR 192"])}let r;void 0!==e["00280100"]&&(r=e["00280100"].value[0]);let a=132,o=0;const s=[],l=[];let c,u,h=0;const d=new Je("0002","0000"),S=new Je("0002","0001"),g=new Je("0002","0012"),p=new Je("0002","0013"),f=Object.keys(e);for(let t=0,i=f.length;t<i;++t){const i=e[f[t]];i.tag=$e(f[t]),c=$y(this,mv,bv).call(this,i),null===c||d.equals(c.tag)||S.equals(c.tag)||g.equals(c.tag)||p.equals(c.tag)||(o=0,Rv(c),$y(this,Cv,Fv).call(this,c,c.value,n,r),u=c.tag.getGroupName(),o+=Zt(c.vr,"Meta Element"!==u&&n),o+=c.vl,"Meta Element"===u?(s.push(c),h+=o):l.push(c),a+=o)}const m=Ev("FileMetaInformationVersion");let y=Zt(m.vr,!1);y+=$y(this,Cv,Fv).call(this,m,[0,1],!1),s.push(m),h+=y,a+=y;const v=Ev("ImplementationClassUID");let D=Zt(v.vr,!1);D+=$y(this,Cv,Fv).call(this,v,[rv("ImplementationClassUID")],!1),s.push(v),h+=D,a+=D;const w=Ev("ImplementationVersionName");let C=Zt(w.vr,!1);C+=$y(this,Cv,Fv).call(this,w,["DWV_0.32.0-beta.0"],!1),s.push(w),h+=C,a+=C;const T=function(e,t){return function(e,t){let n=parseInt(e.getGroup(),16)-parseInt(t.getGroup(),16);return 0===n&&(n=parseInt(e.getElement(),16)-parseInt(t.getElement(),16)),n}(e.tag,t.tag)};s.sort(T),l.sort(T);const I=Ev("FileMetaInformationGroupLength");let L=Zt(I.vr,!1);L+=$y(this,Cv,Fv).call(this,I,new Uint32Array([h]),!1),a+=L;const b=new ArrayBuffer(a),P=new _y(b),A=new _y(b,!i);let O=128;O=P.writeUint8Array(O,$y(this,pv,Iv).call(this,"DICM")),O=$y(this,wv,xv).call(this,P,I,O,!1);for(let e=0,t=s.length;e<t;++e)O=$y(this,wv,xv).call(this,P,s[e],O,!1);const x=132+L+h;O!==x&&re.warn("Bad size calculation... meta offset: "+O+", calculated size:"+x+" (diff:"+(O-x)+")");for(let e=0,t=l.length;e<t;++e)O=$y(this,wv,xv).call(this,A,l[e],O,n);return O!==a&&re.warn("Bad size calculation... final offset: "+O+", calculated size:"+a+" (diff:"+(O-a)+")"),b}}function Iv(e){return ev(this,Sv).encode(e)}function Lv(e){return ev(this,gv).encode(e)}function bv(e){const t=e.tag.getGroupName(),n=e.tag.getNameFromDictionary();let i;return i=void 0!==ev(this,dv)[e.tag.getKey()]?ev(this,dv)[e.tag.getKey()]:void 0!==n&&void 0!==ev(this,dv)[n]?ev(this,dv)[n]:void 0!==ev(this,dv)[t]?ev(this,dv)[t]:ev(this,dv).default,ev(this,uv)[i.action](e,i.value)}function Pv(e,t,n,i){let r=null;for(let a=0;a<n.length;++a){r=n[a];const o=Object.keys(r);if(0===o.length)continue;let s=!1;void 0!==r.FFFEE000.undefinedLength&&(s=r.FFFEE000.undefinedLength);const l={tag:et(),vr:"NONE",vl:s?4294967295:r.FFFEE000.vl,value:[]};t=$y(this,wv,xv).call(this,e,l,t,i);for(let n=0;n<o.length;++n)"FFFEE000"!==o[n]&&"FFFEE00D"!==o[n]&&(t=$y(this,wv,xv).call(this,e,r[o[n]],t,i));if(s){const n={tag:nt(),vr:"NONE",vl:0,value:[]};t=$y(this,wv,xv).call(this,e,n,t,i)}}return t}function Av(e,t,n,i,r){const a=n;if("NONE"===t.vr);else if(i instanceof Uint8Array)n=i.length===8*t.vl?e.writeBinaryArray(n,i):e.writeUint8Array(n,i);else if(i instanceof Int8Array)n=e.writeInt8Array(n,i);else if(i instanceof Uint16Array)n=e.writeUint16Array(n,i);else if(i instanceof Int16Array)n=e.writeInt16Array(n,i);else if(i instanceof Uint32Array)n=e.writeUint32Array(n,i);else if(i instanceof Int32Array)n=e.writeInt32Array(n,i);else if(i instanceof BigUint64Array)n=e.writeUint64Array(n,i);else if(i instanceof BigInt64Array)n=e.writeInt64Array(n,i);else{const a=He[t.vr];if(void 0!==a)if("Uint8"===a)n=e.writeUint8Array(n,i);else if("Uint16"===a)n=e.writeUint16Array(n,i);else if("Int16"===a)n=e.writeInt16Array(n,i);else if("Uint32"===a)n=e.writeUint32Array(n,i);else if("Int32"===a)n=e.writeInt32Array(n,i);else if("Uint64"===a)n=e.writeUint64Array(n,i);else if("Int64"===a)n=e.writeInt64Array(n,i);else if("Float32"===a)n=e.writeFloat32Array(n,i);else if("Float64"===a)n=e.writeFloat64Array(n,i);else{if("string"!==a)throw Error("Unknown VR type: "+a);n=e.writeUint8Array(n,i)}else if("SQ"===t.vr)n=$y(this,yv,Pv).call(this,e,n,i,r);else if("AT"===t.vr)for(let t=0;t<i.length;++t){const r=i[t]+"",a=r.substring(1,5),o=r.substring(6,10),s=[parseInt(a,16),parseInt(o,16)];n=e.writeUint16Array(n,s)}else re.warn("Unknown VR: "+t.vr)}if("SQ"!==t.vr&&"NONE"!==t.vr){const e=n-a;e!==t.vl&&re.warn("Offset difference and VL are not equal: "+e+" != "+t.vl+", vr:"+t.vr)}return n}function Ov(e,t,n,i,r){let a=!1;if(void 0!==t.undefinedLength&&(a=t.undefinedLength),a){const a={};a.FFFEE000={tag:et(),vr:"NONE",vl:0,value:[]};for(let e=0;e<i.length;++e)a[e]={tag:et(),vr:t.vr,vl:i[e].length,value:i[e]};n=$y(this,yv,Pv).call(this,e,n,[a],r)}else{let a=i[0];i.length>1&&(a=function(e){const t=e.length,n=e[0].length;if(void 0===n)return e;const i=t*n,r=new e[0].constructor(i);for(let i=0;i<t;i++){const t=i*n;r.set(e[i],t)}return r}(i)),n=$y(this,vv,Av).call(this,e,t,n,a,r)}return n}function xv(e,t,n,i){const r=t.tag.isWithVR(),a=!(!i&&r)||_t(t.vr);n=e.writeHex(n,t.tag.getGroup()),n=e.writeHex(n,t.tag.getElement());let o=t.vr;ev(this,cv)&&t.tag.isPrivate()&&"SQ"===o&&(re.warn("Write element using VR=UN for private sequence."),o="UN"),r&&!i&&(n=e.writeUint8Array(n,$y(this,pv,Iv).call(this,o)),a&&(n+=2));let s=!1;("SQ"===t.vr||ot(t.tag))&&void 0!==t.undefinedLength&&(s=t.undefinedLength);let l=!1;tt(t.tag)&&void 0!==t.undefinedLength&&(l=t.undefinedLength);let c=t.vl;(s||l)&&(c=4294967295),n=a?e.writeUint32(n,c):e.writeUint16(n,c);let u=t.value;if(void 0===u&&(u=[]),n=ot(t.tag)?$y(this,Dv,Ov).call(this,e,t,n,u,i):$y(this,vv,Av).call(this,e,t,n,u,i),s){const t={tag:it(),vr:"NONE",vl:0,value:[]};n=$y(this,wv,xv).call(this,e,t,n,i)}return n}function Fv(e,t,n,i){let r=0;if("SQ"===e.vr){if(null!==t&&0!==t){const a=[];let o,s=!1;void 0!==e.undefinedLength&&(s=e.undefinedLength,delete e.undefinedLength);for(let e=0;e<t.length;++e){const l=t[e],c={};let u=0;if(null===l||0===l)continue;const h=Object.keys(l);for(let e=0,t=h.length;e<t;++e){const t=h[e],r=l[t];r.tag=$e(t),tt(r.tag)||(u+=$y(this,Cv,Fv).call(this,r,r.value,n,i),c[t]=r,u+=Zt(r.vr,n))}const d={tag:et(),vr:"NONE",vl:u,value:[]};s&&(d.undefinedLength=s),o=d.tag.getKey(),c[o]=d,u+=Zt(d.vr,n),s&&(u+=Zt("NONE",n)),r+=u,a.push(c)}s&&(r+=Zt("NONE",n)),e.value=a,e.vl=r,s&&(e.undefinedLength=s)}}else{if(ov(a=e.vr)||"OB"===a){const n=function(e){let t="";return ov(e)&&(t="UI"===e?"\0":" "),t}(e.vr);if(ov(e.vr)){let i;ze.includes(e.vr)?(t=$y(this,fv,Lv).call(this,t.join("\\")),i=$y(this,fv,Lv).call(this,n)):(t=$y(this,pv,Iv).call(this,t.join("\\")),i=$y(this,pv,Iv).call(this,n)),av(t.length)||(t=sv(t,i))}else"OB"===e.vr&&(t=function(e){if(null==e||void 0===e.length)throw new Error("Cannot pad undefined or null OB value.");if(0!==e.length&&void 0!==e[0].length){let t=0;for(let n=0;n<e.length;++n)t+=e[n].length;av(t)||(e[e.length-1]=sv(e[e.length-1],[0]))}else av(e.length)||(e=sv(e,[0]));return e}(t))}if(r=0,"AT"===e.vr)r=4*t.length;else if("xs"===e.vr)r=t.length*Uint16Array.BYTES_PER_ELEMENT;else if(function(e){const t=He[e];return void 0!==t&&"string"!==t}(e.vr)||"ox"===e.vr){if(ot(e.tag)&&Array.isArray(t)){r=0;for(let e=0;e<t.length;++e)r+=t[e].length}else r=t.length;const a=He[e.vr];if(ot(e.tag)||"ox"===e.vr)if(e.undefinedLength){const e=Zt("NONE",n);r+=e,r+=e*t.length,r+=e}else void 0!==i&&(1===i?r/=8:16===i&&(r*=Uint16Array.BYTES_PER_ELEMENT));else{if(void 0===a)throw Error("Unsupported element: "+e.vr);{const e=function(e){let t;return"Uint8"===e?t=Uint8Array.BYTES_PER_ELEMENT:"Uint16"===e?t=Uint16Array.BYTES_PER_ELEMENT:"Int16"===e?t=Int16Array.BYTES_PER_ELEMENT:"Uint32"===e?t=Uint32Array.BYTES_PER_ELEMENT:"Int32"===e?t=Int32Array.BYTES_PER_ELEMENT:"Float32"===e?t=Float32Array.BYTES_PER_ELEMENT:"Float64"===e?t=Float64Array.BYTES_PER_ELEMENT:"Uint64"===e?t=BigUint64Array.BYTES_PER_ELEMENT:"Int64"===e&&(t=BigInt64Array.BYTES_PER_ELEMENT),t}(a);if(void 0===e)throw Error("Unknown bytes per element for VR type: "+a);r*=e}}}else r=t.length;e.value=t,e.vl=r}var a;return r}function Rv(e){if("UN"===e.vr){const t=e.tag.getVrFromDictionary();void 0!==t&&e.vr!==t&&(e.vr=t,re.info("Element "+e.tag.getGroup()+" "+e.tag.getElement()+" VR changed from UN to "+e.vr))}}function Ev(e){const t=st(e);return{tag:t,vr:t.getVrFromDictionary()}}function Mv(e){const t=Object.keys(e),n={};for(let i=0,r=t.length;i<r;++i){const r=st(t[i]);if(!r)continue;const a=r.getVrFromDictionary();let o,s=!1;const l=e[t[i]];if("SQ"===a){const e=[];if(void 0!==l.undefinedLength&&(s=l.undefinedLength),void 0!==l.value&&null!==l.value)for(let t=0;t<l.value.length;++t)e.push(Mv(l.value[t]));else re.trace("Undefined or null jsonTag SQ value.");o=e}else o=Array.isArray(l)?l:[l];const c={tag:r,vr:a,value:o};s&&(c.undefinedLength=s),n[r.getKey()]=c}return n}}(),o}()}));
2
+ //# sourceMappingURL=dwv.min.js.map