@jax-data-science/sci-image-visualizer 0.8.3 → 0.9.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/README.md +201 -460
- package/esm2022/index.mjs +28 -15
- package/esm2022/lib/channel-histogram/channel-histogram.component.mjs +163 -91
- package/esm2022/lib/contracts/capabilities.contract.mjs +4 -3
- package/esm2022/lib/contracts/cell-segmenter.contract.mjs +1 -1
- package/esm2022/lib/contracts/channel-histogram-api.contract.mjs +5 -1
- package/esm2022/lib/contracts/color.mjs +60 -0
- package/esm2022/lib/contracts/colormap-lut.mjs +213 -57
- package/esm2022/lib/contracts/coordinate-transform.contract.mjs +1 -1
- package/esm2022/lib/contracts/display-types.mjs +11 -1
- package/esm2022/lib/contracts/instance-segmenter.contract.mjs +1 -1
- package/esm2022/lib/contracts/intensity.mjs +48 -5
- package/esm2022/lib/contracts/plot-type-contribution.contract.mjs +1 -1
- package/esm2022/lib/contracts/plot-type.mjs +134 -17
- package/esm2022/lib/contracts/ports/image-state.port.mjs +4 -1
- package/esm2022/lib/contracts/ports/preferences.port.mjs +5 -1
- package/esm2022/lib/contracts/ports/region-io.port.mjs +2 -1
- package/esm2022/lib/contracts/ports/spatial-data.port.mjs +5 -1
- package/esm2022/lib/contracts/ports/tile-access.port.mjs +2 -1
- package/esm2022/lib/contracts/region-editor-api.contract.mjs +1 -1
- package/esm2022/lib/contracts/region-overlay.contract.mjs +1 -1
- package/esm2022/lib/contracts/sam.contract.mjs +1 -1
- package/esm2022/lib/contracts/semantic-segmenter.contract.mjs +1 -1
- package/esm2022/lib/contracts/spatial-dataset.contract.mjs +3 -1
- package/esm2022/lib/contracts/toolbar-tool.contract.mjs +6 -4
- package/esm2022/lib/contracts/visualizer.contract.mjs +1 -1
- package/esm2022/lib/contracts/viz-config.mjs +2 -1
- package/esm2022/lib/geometry/contour.mjs +63 -0
- package/esm2022/lib/geometry/raster.mjs +98 -0
- package/esm2022/lib/geometry/ring.mjs +201 -0
- package/esm2022/lib/hex-color-picker/hex-color-picker.component.mjs +202 -102
- package/esm2022/lib/implementations/base-store-visualizer.mjs +201 -48
- package/esm2022/lib/implementations/napari-js/napari-axes-gizmo.mjs +65 -0
- package/esm2022/lib/implementations/napari-js/napari-display-state.mjs +136 -0
- package/esm2022/lib/implementations/napari-js/napari-helpers.mjs +199 -0
- package/esm2022/lib/implementations/napari-js/napari-image-2d-scene.mjs +602 -0
- package/esm2022/lib/implementations/napari-js/napari-loading-badge.mjs +3 -4
- package/esm2022/lib/implementations/napari-js/napari-loading-state.mjs +66 -0
- package/esm2022/lib/implementations/napari-js/napari-region-overlay.mjs +157 -591
- package/esm2022/lib/implementations/napari-js/napari-scene.mjs +2 -0
- package/esm2022/lib/implementations/napari-js/napari-spatial-2d-scene.mjs +614 -0
- package/esm2022/lib/implementations/napari-js/napari-spatial-3d-scene.mjs +769 -0
- package/esm2022/lib/implementations/napari-js/napari-spatial-encoding.mjs +199 -0
- package/esm2022/lib/implementations/napari-js/napari-spatial-hover.mjs +263 -0
- package/esm2022/lib/implementations/napari-js/napari-spatial-scene.mjs +159 -0
- package/esm2022/lib/implementations/napari-js/napari-spatial-tiles.mjs +106 -1408
- package/esm2022/lib/implementations/napari-js/napari-spatial-tooltip.mjs +2 -2
- package/esm2022/lib/implementations/napari-js/napari-surface-scene.mjs +271 -0
- package/esm2022/lib/implementations/napari-js/napari-tile-client.mjs +562 -0
- package/esm2022/lib/implementations/napari-js/napari-tool-bridge.mjs +344 -0
- package/esm2022/lib/implementations/napari-js/napari-visualizer.service.mjs +358 -4218
- package/esm2022/lib/implementations/napari-js/napari-volume-scene.mjs +439 -0
- package/esm2022/lib/implementations/napari-js/napari-volume-z-handle.mjs +6 -6
- package/esm2022/lib/implementations/napari-js/region-overlay/overlay-projection.mjs +96 -0
- package/esm2022/lib/implementations/napari-js/region-overlay/region-edit.mjs +35 -0
- package/esm2022/lib/implementations/napari-js/region-overlay/region-svg-renderer.mjs +182 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/categorical-lookup.mjs +30 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/cell-layers.mjs +274 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/density-layer.mjs +144 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/layer-groups.mjs +165 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/plan-context.mjs +78 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/transcript-hover.mjs +182 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/transcript-jobs.mjs +369 -0
- package/esm2022/lib/implementations/napari-js/spatial-tiles/transcript-layers.mjs +306 -0
- package/esm2022/lib/implementations/osd/display-pipeline.mjs +102 -40
- package/esm2022/lib/implementations/osd/histogram-sampler.mjs +56 -31
- package/esm2022/lib/implementations/osd/openseadragon-viewer-options.mjs +128 -0
- package/esm2022/lib/implementations/osd/openseadragon-visualizer.service.mjs +333 -1685
- package/esm2022/lib/implementations/osd/osd-coordinate-transform.mjs +1 -1
- package/esm2022/lib/implementations/osd/osd-coords.mjs +5 -6
- package/esm2022/lib/implementations/osd/osd-export.mjs +122 -0
- package/esm2022/lib/implementations/osd/osd-lib.mjs +15 -1
- package/esm2022/lib/implementations/osd/osd-navigator-chrome.mjs +205 -0
- package/esm2022/lib/implementations/osd/osd-pixel-readback.mjs +68 -0
- package/esm2022/lib/implementations/osd/osd-region-overlay-draw.mjs +153 -0
- package/esm2022/lib/implementations/osd/osd-region-overlay.mjs +185 -718
- package/esm2022/lib/implementations/osd/osd-scale-bar.mjs +52 -60
- package/esm2022/lib/implementations/osd/osd-tile-source.mjs +105 -0
- package/esm2022/lib/implementations/osd/osd-viewer-like.mjs +2 -0
- package/esm2022/lib/implementations/osd/osd-viewer-mount.mjs +44 -0
- package/esm2022/lib/implementations/osd/osd-viewport.mjs +184 -0
- package/esm2022/lib/implementations/osd/osd-zoom.mjs +7 -1
- package/esm2022/lib/implementations/osd/simple-source.mjs +395 -0
- package/esm2022/lib/implementations/osd/slice-cache.mjs +53 -48
- package/esm2022/lib/implementations/osd/tile-client.mjs +32 -11
- package/esm2022/lib/implementations/osd/tile-recolor.mjs +330 -0
- package/esm2022/lib/implementations/plotly/omics-trace-builders.mjs +161 -73
- package/esm2022/lib/implementations/plotly/plotly-coordinate-transform.mjs +1 -1
- package/esm2022/lib/implementations/plotly/plotly-image-loader.mjs +112 -0
- package/esm2022/lib/implementations/plotly/plotly-image-recolor.mjs +178 -0
- package/esm2022/lib/implementations/plotly/plotly-intensity-inset.mjs +33 -0
- package/esm2022/lib/implementations/plotly/plotly-isosurface-controls.mjs +83 -0
- package/esm2022/lib/implementations/plotly/plotly-layouts.mjs +121 -0
- package/esm2022/lib/implementations/plotly/plotly-readback.mjs +117 -0
- package/esm2022/lib/implementations/plotly/plotly-region-overlay.mjs +19 -10
- package/esm2022/lib/implementations/plotly/plotly-shape-projection.mjs +223 -0
- package/esm2022/lib/implementations/plotly/plotly-trace-builders.mjs +79 -19
- package/esm2022/lib/implementations/plotly/plotly-zoom-controller.mjs +223 -0
- package/esm2022/lib/implementations/plotly/plotly.service.mjs +439 -1655
- package/esm2022/lib/implementations/region-centroids.mjs +47 -0
- package/esm2022/lib/implementations/simple-slice-access.service.mjs +22 -12
- package/esm2022/lib/implementations/spatial-data-http/spatial-data-http.service.mjs +172 -92
- package/esm2022/lib/implementations/spatial-data-http/spatial-wire.mjs +103 -22
- package/esm2022/lib/implementations/tile-server/index.mjs +6 -0
- package/esm2022/lib/implementations/tile-server/native-histogram.mjs +30 -0
- package/esm2022/lib/implementations/tile-server/poll-descriptor.mjs +65 -0
- package/esm2022/lib/implementations/tile-server/tile-protocol.mjs +42 -0
- package/esm2022/lib/implementations/tile-server/transport.mjs +135 -0
- package/esm2022/lib/intensity/intensity-profile.mjs +107 -0
- package/esm2022/lib/intensity/intensity-profile.service.mjs +223 -0
- package/esm2022/lib/intensity-inset/intensity-inset.component.mjs +133 -0
- package/esm2022/lib/models/bezier.mjs +1 -11
- package/esm2022/lib/models/class-preset.mjs +41 -3
- package/esm2022/lib/models/geometry.mjs +27 -164
- package/esm2022/lib/models/polygon-edit.mjs +254 -0
- package/esm2022/lib/models/polygon-factory.mjs +118 -0
- package/esm2022/lib/models/region-clone.mjs +68 -0
- package/esm2022/lib/models/region-geojson.mjs +373 -0
- package/esm2022/lib/models/region.mjs +34 -33
- package/esm2022/lib/models/shape.mjs +18 -16
- package/esm2022/lib/plot-mode/contribution-host.mjs +297 -0
- package/esm2022/lib/plot-mode/plot-mode-controller.mjs +9 -6
- package/esm2022/lib/plot-mode/plot-type-menu.mjs +85 -0
- package/esm2022/lib/plot-mode/tool-params-model.mjs +87 -0
- package/esm2022/lib/plot.utilities.mjs +296 -473
- package/esm2022/lib/processing/image-crop.mjs +1 -1
- package/esm2022/lib/processing/processing-image.mjs +28 -15
- package/esm2022/lib/provide-visualization.mjs +40 -14
- package/esm2022/lib/region-editor/classes-panel/classes-panel.component.mjs +99 -0
- package/esm2022/lib/region-editor/file-stem.mjs +13 -0
- package/esm2022/lib/region-editor/manage-classes-dialog/manage-classes-dialog.component.mjs +118 -0
- package/esm2022/lib/region-editor/mask-export.service.mjs +98 -0
- package/esm2022/lib/region-editor/mask-raster.mjs +11 -5
- package/esm2022/lib/region-editor/region-color-dialog/region-color-dialog.component.mjs +56 -0
- package/esm2022/lib/region-editor/region-editor-help/region-editor-help.component.mjs +28 -0
- package/esm2022/lib/region-editor/region-editor.component.mjs +402 -651
- package/esm2022/lib/region-editor/region-metrics.mjs +68 -0
- package/esm2022/lib/region-editor/region-persistence.service.mjs +134 -0
- package/esm2022/lib/region-editor/region-table/region-table.component.mjs +153 -0
- package/esm2022/lib/region-editor/save-mask-dialog/save-mask-dialog.component.mjs +91 -0
- package/esm2022/lib/region-editor/save-regions-dialog/save-regions-dialog.component.mjs +92 -0
- package/esm2022/lib/region-ops.service.mjs +28 -70
- package/esm2022/lib/region-overlay/region-geometry.mjs +360 -0
- package/esm2022/lib/region-overlay/region-hit-test.mjs +103 -0
- package/esm2022/lib/region-overlay/svg-region-renderer.mjs +228 -0
- package/esm2022/lib/render-orchestrator.mjs +14 -11
- package/esm2022/lib/render-session.mjs +207 -0
- package/esm2022/lib/routing-visualizer.service.mjs +459 -411
- package/esm2022/lib/spatial/density-raster.mjs +14 -0
- package/esm2022/lib/spatial/embedding-compute-coordinator.mjs +239 -0
- package/esm2022/lib/spatial/embedding-compute.mjs +43 -10
- package/esm2022/lib/spatial/gene-search.mjs +1 -1
- package/esm2022/lib/spatial/glyphs.mjs +97 -0
- package/esm2022/lib/spatial/lod.mjs +187 -0
- package/esm2022/lib/spatial/spatial-controls.facade.mjs +200 -0
- package/esm2022/lib/spatial/spatial-density.mjs +25 -16
- package/esm2022/lib/spatial/spatial-encoding.mjs +26 -82
- package/esm2022/lib/spatial/spatial-expression.mjs +43 -42
- package/esm2022/lib/spatial/spatial-framing.mjs +1 -1
- package/esm2022/lib/spatial/spatial-heatmap.mjs +6 -3
- package/esm2022/lib/spatial/spatial-hover.mjs +5 -33
- package/esm2022/lib/spatial/spatial-panel-model.mjs +282 -0
- package/esm2022/lib/spatial/spatial-sections.mjs +1 -1
- package/esm2022/lib/spatial/spatial-selection.mjs +33 -46
- package/esm2022/lib/spatial/spatial-tile-merge.mjs +219 -0
- package/esm2022/lib/spatial/spatial-tiles.mjs +12 -648
- package/esm2022/lib/spatial/spatial-volume-image.mjs +2 -4
- package/esm2022/lib/spatial/stats.mjs +71 -0
- package/esm2022/lib/spatial/transcript-grouping.mjs +307 -0
- package/esm2022/lib/spatial-controls/spatial-cells-panel/spatial-cells-panel.component.mjs +150 -0
- package/esm2022/lib/spatial-controls/spatial-charts/chart-data-model.mjs +309 -0
- package/esm2022/lib/spatial-controls/spatial-charts/chart-help.mjs +145 -0
- package/esm2022/lib/spatial-controls/spatial-charts/plotly-chart-host.mjs +158 -0
- package/esm2022/lib/spatial-controls/spatial-charts/spatial-chart-window/spatial-chart-window.component.mjs +47 -0
- package/esm2022/lib/spatial-controls/spatial-charts/spatial-charts.component.mjs +297 -802
- package/esm2022/lib/spatial-controls/spatial-charts/spatial-embedding-controls/spatial-embedding-controls.component.mjs +89 -0
- package/esm2022/lib/spatial-controls/spatial-charts/spatial-heatmap-controls/spatial-heatmap-controls.component.mjs +52 -0
- package/esm2022/lib/spatial-controls/spatial-controls.component.mjs +143 -1238
- package/esm2022/lib/spatial-controls/spatial-gene-picker.mjs +153 -0
- package/esm2022/lib/spatial-controls/spatial-gene-tree/spatial-gene-tree.component.mjs +241 -0
- package/esm2022/lib/spatial-controls/spatial-groups-panel/spatial-groups-panel.component.mjs +193 -0
- package/esm2022/lib/spatial-controls/spatial-key/spatial-key.component.mjs +132 -0
- package/esm2022/lib/spatial-controls/spatial-key/spatial-key.model.mjs +67 -0
- package/esm2022/lib/spatial-controls/spatial-marker-genes-form/spatial-marker-genes-form.component.mjs +147 -0
- package/esm2022/lib/spatial-controls/spatial-observations-panel/spatial-observations-panel.component.mjs +300 -0
- package/esm2022/lib/spatial-controls/spatial-transcripts-panel/spatial-transcripts-panel.component.mjs +370 -0
- package/esm2022/lib/store/class-color.util.mjs +46 -3
- package/esm2022/lib/store/region-history.mjs +146 -0
- package/esm2022/lib/store/region-scope-cache.mjs +140 -0
- package/esm2022/lib/store/region-selection.mjs +82 -0
- package/esm2022/lib/store/region-store.service.mjs +279 -675
- package/esm2022/lib/store/spatial-selection.service.mjs +2 -2
- package/esm2022/lib/store/visualizer-store.service.mjs +49 -71
- package/esm2022/lib/toast-outlets.mjs +5 -4
- package/esm2022/lib/toolbar/brush/brush-tool.service.mjs +92 -434
- package/esm2022/lib/toolbar/canvas-tools.mjs +20 -0
- package/esm2022/lib/toolbar/crop/slide-crop.mjs +26 -42
- package/esm2022/lib/toolbar/plot-type-selector/plot-type-selector.component.mjs +85 -0
- package/esm2022/lib/toolbar/region-tools/region-tool-buttons.mjs +74 -0
- package/esm2022/lib/toolbar/region-tools/region-tools.component.mjs +114 -0
- package/esm2022/lib/toolbar/segmentation/cell-segment-tool.service.mjs +74 -78
- package/esm2022/lib/toolbar/segmentation/cellpose-segmenter.service.mjs +50 -8
- package/esm2022/lib/toolbar/segmentation/onnx-sam-session.mjs +61 -42
- package/esm2022/lib/toolbar/segmentation/pending-calls.mjs +47 -0
- package/esm2022/lib/toolbar/segmentation/sam-model-registry.mjs +12 -4
- package/esm2022/lib/toolbar/segmentation/sam-onnx-core.mjs +70 -14
- package/esm2022/lib/toolbar/segmentation/sam-point-tool.service.mjs +135 -172
- package/esm2022/lib/toolbar/segmentation/sam-prompt.mjs +9 -90
- package/esm2022/lib/toolbar/segmentation/sam-session.service.mjs +183 -0
- package/esm2022/lib/toolbar/segmentation/sam-tool.service.mjs +95 -150
- package/esm2022/lib/toolbar/segmentation/segmentation-commit.mjs +12 -0
- package/esm2022/lib/toolbar/segmentation/segmentation-runner.mjs +108 -0
- package/esm2022/lib/toolbar/segmentation-tools/segmentation-tools.component.mjs +155 -0
- package/esm2022/lib/toolbar/stack-controls/stack-controls.component.mjs +81 -0
- package/esm2022/lib/toolbar/tool-kit/async-tool-status.mjs +37 -0
- package/esm2022/lib/toolbar/tool-kit/canvas-tool-manager.mjs +63 -0
- package/esm2022/lib/toolbar/tool-kit/canvas-tool.mjs +2 -0
- package/esm2022/lib/toolbar/tool-kit/frame-pixels.mjs +108 -0
- package/esm2022/lib/toolbar/tool-kit/mask-stroke-editor.mjs +306 -0
- package/esm2022/lib/toolbar/tool-kit/matrix-frame.mjs +61 -0
- package/esm2022/lib/toolbar/tool-kit/tool-overlay.mjs +140 -0
- package/esm2022/lib/toolbar/tool-kit/undo-gesture.mjs +24 -0
- package/esm2022/lib/toolbar/tool-slider/tool-slider.component.mjs +63 -0
- package/esm2022/lib/toolbar/toolbar-help-dialog/toolbar-help-dialog.component.mjs +50 -0
- package/esm2022/lib/toolbar/toolbar.component.mjs +68 -117
- package/esm2022/lib/toolbar/vertex-eraser/vertex-eraser-tool.service.mjs +93 -115
- package/esm2022/lib/toolbar/view-controls/view-controls.component.mjs +107 -0
- package/esm2022/lib/toolbar/wand/wand-region-grow.mjs +321 -0
- package/esm2022/lib/toolbar/wand/wand-tool.service.mjs +121 -416
- package/esm2022/lib/toolbar/wand/wand.service.mjs +30 -894
- package/esm2022/lib/toolbar/zoom-to-box/zoom-to-box-tool.service.mjs +48 -90
- package/esm2022/lib/util/mark-for-check.mjs +17 -0
- package/esm2022/lib/util/supersede.mjs +56 -0
- package/esm2022/lib/visualization.module.mjs +39 -141
- package/esm2022/lib/visualizer/floating-drag.directive.mjs +58 -0
- package/esm2022/lib/visualizer/region-actions.mjs +149 -0
- package/esm2022/lib/visualizer/region-load.mjs +60 -0
- package/esm2022/lib/visualizer/spatial-dataset-binder.mjs +163 -0
- package/esm2022/lib/visualizer/tool-modes.mjs +113 -0
- package/esm2022/lib/visualizer/viewer-shortcuts.mjs +167 -0
- package/esm2022/lib/visualizer/visualizer-context-menu.mjs +119 -0
- package/esm2022/lib/visualizer.component.mjs +480 -1902
- package/esm2022/lib/workers/spatial-math-ops.mjs +43 -0
- package/esm2022/lib/workers/spatial-math-worker.mjs +10 -0
- package/esm2022/lib/workers/spatial-math.mjs +190 -0
- package/fesm2022/jax-data-science-sci-image-visualizer-jax-data-science-sci-image-visualizer-Csxlnq7I.mjs +41083 -0
- package/fesm2022/jax-data-science-sci-image-visualizer-jax-data-science-sci-image-visualizer-Csxlnq7I.mjs.map +1 -0
- package/fesm2022/jax-data-science-sci-image-visualizer-onnx-sam-session-Bkujqg7m.mjs +238 -0
- package/fesm2022/jax-data-science-sci-image-visualizer-onnx-sam-session-Bkujqg7m.mjs.map +1 -0
- package/fesm2022/jax-data-science-sci-image-visualizer-spatial-math-worker-BzVFFqGS.mjs +12 -0
- package/fesm2022/jax-data-science-sci-image-visualizer-spatial-math-worker-BzVFFqGS.mjs.map +1 -0
- package/fesm2022/jax-data-science-sci-image-visualizer.mjs +41 -34467
- package/fesm2022/jax-data-science-sci-image-visualizer.mjs.map +1 -1
- package/fesm2022/mask.worker.js +36 -917
- package/fesm2022/onnx-sam.worker.js +52 -16
- package/fesm2022/spatial-math.worker.js +471 -0
- package/fesm2022/tsne.worker.js +32 -15
- package/index.d.ts +13 -10
- package/lib/channel-histogram/channel-histogram.component.d.ts +53 -43
- package/lib/contracts/capabilities.contract.d.ts +4 -2
- package/lib/contracts/cell-segmenter.contract.d.ts +1 -0
- package/lib/contracts/channel-histogram-api.contract.d.ts +4 -0
- package/lib/contracts/color.d.ts +27 -0
- package/lib/contracts/colormap-lut.d.ts +19 -4
- package/lib/contracts/coordinate-transform.contract.d.ts +3 -3
- package/lib/contracts/display-types.d.ts +21 -0
- package/lib/contracts/instance-segmenter.contract.d.ts +5 -0
- package/lib/contracts/intensity.d.ts +13 -2
- package/lib/contracts/plot-type.d.ts +3 -1
- package/lib/contracts/ports/image-state.port.d.ts +6 -2
- package/lib/contracts/ports/preferences.port.d.ts +4 -0
- package/lib/contracts/ports/region-io.port.d.ts +1 -0
- package/lib/contracts/ports/spatial-data.port.d.ts +4 -10
- package/lib/contracts/ports/tile-access.port.d.ts +1 -0
- package/lib/contracts/region-editor-api.contract.d.ts +1 -1
- package/lib/contracts/region-overlay.contract.d.ts +5 -0
- package/lib/contracts/sam.contract.d.ts +7 -0
- package/lib/contracts/semantic-segmenter.contract.d.ts +6 -0
- package/lib/contracts/spatial-dataset.contract.d.ts +19 -6
- package/lib/contracts/toolbar-tool.contract.d.ts +1 -0
- package/lib/contracts/visualizer.contract.d.ts +221 -54
- package/lib/contracts/viz-config.d.ts +1 -0
- package/lib/geometry/contour.d.ts +24 -0
- package/lib/geometry/raster.d.ts +42 -0
- package/lib/geometry/ring.d.ts +67 -0
- package/lib/hex-color-picker/hex-color-picker.component.d.ts +61 -27
- package/lib/implementations/base-store-visualizer.d.ts +61 -15
- package/lib/implementations/napari-js/napari-axes-gizmo.d.ts +36 -0
- package/lib/implementations/napari-js/napari-display-state.d.ts +76 -0
- package/lib/implementations/napari-js/napari-helpers.d.ts +129 -0
- package/lib/implementations/napari-js/napari-image-2d-scene.d.ts +162 -0
- package/lib/implementations/napari-js/napari-loading-badge.d.ts +0 -1
- package/lib/implementations/napari-js/napari-loading-state.d.ts +30 -0
- package/lib/implementations/napari-js/napari-region-overlay.d.ts +62 -70
- package/lib/implementations/napari-js/napari-scene.d.ts +93 -0
- package/lib/implementations/napari-js/napari-spatial-2d-scene.d.ts +163 -0
- package/lib/implementations/napari-js/napari-spatial-3d-scene.d.ts +212 -0
- package/lib/implementations/napari-js/napari-spatial-encoding.d.ts +114 -0
- package/lib/implementations/napari-js/napari-spatial-hover.d.ts +89 -0
- package/lib/implementations/napari-js/napari-spatial-scene.d.ts +118 -0
- package/lib/implementations/napari-js/napari-spatial-tiles.d.ts +56 -263
- package/lib/implementations/napari-js/napari-spatial-tooltip.d.ts +1 -1
- package/lib/implementations/napari-js/napari-surface-scene.d.ts +76 -0
- package/lib/implementations/napari-js/napari-tile-client.d.ts +214 -0
- package/lib/implementations/napari-js/napari-tool-bridge.d.ts +179 -0
- package/lib/implementations/napari-js/napari-visualizer.service.d.ts +121 -883
- package/lib/implementations/napari-js/napari-volume-scene.d.ts +104 -0
- package/lib/implementations/napari-js/napari-volume-z-handle.d.ts +8 -12
- package/lib/implementations/napari-js/region-overlay/overlay-projection.d.ts +59 -0
- package/lib/implementations/napari-js/region-overlay/region-edit.d.ts +15 -0
- package/lib/implementations/napari-js/region-overlay/region-svg-renderer.d.ts +54 -0
- package/lib/implementations/napari-js/spatial-tiles/categorical-lookup.d.ts +26 -0
- package/lib/implementations/napari-js/spatial-tiles/cell-layers.d.ts +70 -0
- package/lib/implementations/napari-js/spatial-tiles/density-layer.d.ts +61 -0
- package/lib/implementations/napari-js/spatial-tiles/layer-groups.d.ts +67 -0
- package/lib/implementations/napari-js/spatial-tiles/plan-context.d.ts +38 -0
- package/lib/implementations/napari-js/spatial-tiles/transcript-hover.d.ts +71 -0
- package/lib/implementations/napari-js/spatial-tiles/transcript-jobs.d.ts +105 -0
- package/lib/implementations/napari-js/spatial-tiles/transcript-layers.d.ts +56 -0
- package/lib/implementations/osd/display-pipeline.d.ts +38 -9
- package/lib/implementations/osd/histogram-sampler.d.ts +22 -12
- package/lib/implementations/osd/openseadragon-viewer-options.d.ts +35 -0
- package/lib/implementations/osd/openseadragon-visualizer.service.d.ts +78 -354
- package/lib/implementations/osd/osd-coordinate-transform.d.ts +2 -1
- package/lib/implementations/osd/osd-coords.d.ts +6 -4
- package/lib/implementations/osd/osd-export.d.ts +36 -0
- package/lib/implementations/osd/osd-lib.d.ts +7 -0
- package/lib/implementations/osd/osd-navigator-chrome.d.ts +69 -0
- package/lib/implementations/osd/osd-pixel-readback.d.ts +22 -0
- package/lib/implementations/osd/osd-region-overlay-draw.d.ts +37 -0
- package/lib/implementations/osd/osd-region-overlay.d.ts +36 -48
- package/lib/implementations/osd/osd-scale-bar.d.ts +8 -6
- package/lib/implementations/osd/osd-tile-source.d.ts +49 -0
- package/lib/implementations/osd/osd-viewer-like.d.ts +100 -0
- package/lib/implementations/osd/osd-viewer-mount.d.ts +14 -0
- package/lib/implementations/osd/osd-viewport.d.ts +77 -0
- package/lib/implementations/osd/osd-zoom.d.ts +6 -0
- package/lib/implementations/osd/simple-source.d.ts +161 -0
- package/lib/implementations/osd/slice-cache.d.ts +12 -3
- package/lib/implementations/osd/tile-client.d.ts +11 -14
- package/lib/implementations/osd/tile-recolor.d.ts +141 -0
- package/lib/implementations/plotly/omics-trace-builders.d.ts +32 -20
- package/lib/implementations/plotly/plotly-image-loader.d.ts +49 -0
- package/lib/implementations/plotly/plotly-image-recolor.d.ts +75 -0
- package/lib/implementations/plotly/plotly-intensity-inset.d.ts +8 -0
- package/lib/implementations/plotly/plotly-isosurface-controls.d.ts +38 -0
- package/lib/implementations/plotly/plotly-layouts.d.ts +188 -0
- package/lib/implementations/plotly/plotly-readback.d.ts +41 -0
- package/lib/implementations/plotly/plotly-region-overlay.d.ts +2 -2
- package/lib/implementations/plotly/plotly-shape-projection.d.ts +92 -0
- package/lib/implementations/plotly/plotly-trace-builders.d.ts +23 -12
- package/lib/implementations/plotly/plotly-zoom-controller.d.ts +86 -0
- package/lib/implementations/plotly/plotly.service.d.ts +136 -401
- package/lib/implementations/region-centroids.d.ts +14 -0
- package/lib/implementations/simple-slice-access.service.d.ts +7 -4
- package/lib/implementations/spatial-data-http/spatial-data-http.service.d.ts +42 -18
- package/lib/implementations/spatial-data-http/spatial-wire.d.ts +34 -9
- package/lib/implementations/tile-server/index.d.ts +5 -0
- package/lib/implementations/tile-server/native-histogram.d.ts +25 -0
- package/lib/implementations/tile-server/poll-descriptor.d.ts +39 -0
- package/lib/implementations/tile-server/tile-protocol.d.ts +80 -0
- package/lib/implementations/tile-server/transport.d.ts +62 -0
- package/lib/intensity/intensity-profile.d.ts +66 -0
- package/lib/intensity/intensity-profile.service.d.ts +108 -0
- package/lib/intensity-inset/intensity-inset.component.d.ts +58 -0
- package/lib/models/bezier.d.ts +0 -5
- package/lib/models/class-preset.d.ts +18 -0
- package/lib/models/geometry.d.ts +14 -48
- package/lib/models/polygon-edit.d.ts +72 -0
- package/lib/models/polygon-factory.d.ts +40 -0
- package/lib/models/region-clone.d.ts +20 -0
- package/lib/models/region-geojson.d.ts +17 -0
- package/lib/models/region.d.ts +40 -4
- package/lib/models/shape.d.ts +8 -0
- package/lib/plot-mode/contribution-host.d.ts +125 -0
- package/lib/plot-mode/plot-type-menu.d.ts +60 -0
- package/lib/plot-mode/tool-params-model.d.ts +49 -0
- package/lib/plot.utilities.d.ts +19 -30
- package/lib/processing/processing-image.d.ts +5 -2
- package/lib/provide-visualization.d.ts +19 -2
- package/lib/region-editor/classes-panel/classes-panel.component.d.ts +56 -0
- package/lib/region-editor/file-stem.d.ts +7 -0
- package/lib/region-editor/manage-classes-dialog/manage-classes-dialog.component.d.ts +45 -0
- package/lib/region-editor/mask-export.service.d.ts +54 -0
- package/lib/region-editor/mask-raster.d.ts +2 -8
- package/lib/region-editor/region-color-dialog/region-color-dialog.component.d.ts +29 -0
- package/lib/region-editor/region-editor-help/region-editor-help.component.d.ts +11 -0
- package/lib/region-editor/region-editor.component.d.ts +166 -199
- package/lib/region-editor/region-metrics.d.ts +26 -0
- package/lib/region-editor/region-persistence.service.d.ts +69 -0
- package/lib/region-editor/region-table/region-table.component.d.ts +83 -0
- package/lib/region-editor/save-mask-dialog/save-mask-dialog.component.d.ts +36 -0
- package/lib/region-editor/save-regions-dialog/save-regions-dialog.component.d.ts +37 -0
- package/lib/region-ops.service.d.ts +1 -7
- package/lib/region-overlay/region-geometry.d.ts +157 -0
- package/lib/region-overlay/region-hit-test.d.ts +38 -0
- package/lib/region-overlay/svg-region-renderer.d.ts +110 -0
- package/lib/render-orchestrator.d.ts +6 -2
- package/lib/render-session.d.ts +75 -0
- package/lib/routing-visualizer.service.d.ts +110 -58
- package/lib/spatial/density-raster.d.ts +6 -0
- package/lib/spatial/embedding-compute-coordinator.d.ts +123 -0
- package/lib/spatial/embedding-compute.d.ts +21 -2
- package/lib/spatial/glyphs.d.ts +16 -0
- package/lib/spatial/lod.d.ts +94 -0
- package/lib/spatial/spatial-controls.facade.d.ts +64 -0
- package/lib/spatial/spatial-density.d.ts +15 -5
- package/lib/spatial/spatial-encoding.d.ts +11 -44
- package/lib/spatial/spatial-expression.d.ts +40 -22
- package/lib/spatial/spatial-framing.d.ts +1 -0
- package/lib/spatial/spatial-heatmap.d.ts +2 -0
- package/lib/spatial/spatial-hover.d.ts +4 -16
- package/lib/spatial/spatial-panel-model.d.ts +135 -0
- package/lib/spatial/spatial-selection.d.ts +21 -26
- package/lib/spatial/spatial-tile-merge.d.ts +41 -0
- package/lib/spatial/spatial-tiles.d.ts +9 -256
- package/lib/spatial/stats.d.ts +38 -0
- package/lib/spatial/transcript-grouping.d.ts +119 -0
- package/lib/spatial-controls/spatial-cells-panel/spatial-cells-panel.component.d.ts +64 -0
- package/lib/spatial-controls/spatial-charts/chart-data-model.d.ts +153 -0
- package/lib/spatial-controls/spatial-charts/chart-help.d.ts +69 -0
- package/lib/spatial-controls/spatial-charts/plotly-chart-host.d.ts +98 -0
- package/lib/spatial-controls/spatial-charts/spatial-chart-window/spatial-chart-window.component.d.ts +26 -0
- package/lib/spatial-controls/spatial-charts/spatial-charts.component.d.ts +101 -260
- package/lib/spatial-controls/spatial-charts/spatial-embedding-controls/spatial-embedding-controls.component.d.ts +43 -0
- package/lib/spatial-controls/spatial-charts/spatial-heatmap-controls/spatial-heatmap-controls.component.d.ts +27 -0
- package/lib/spatial-controls/spatial-controls.component.d.ts +68 -448
- package/lib/spatial-controls/spatial-gene-picker.d.ts +86 -0
- package/lib/spatial-controls/spatial-gene-tree/spatial-gene-tree.component.d.ts +102 -0
- package/lib/spatial-controls/spatial-groups-panel/spatial-groups-panel.component.d.ts +72 -0
- package/lib/spatial-controls/spatial-key/spatial-key.component.d.ts +66 -0
- package/lib/spatial-controls/spatial-key/spatial-key.model.d.ts +33 -0
- package/lib/spatial-controls/spatial-marker-genes-form/spatial-marker-genes-form.component.d.ts +64 -0
- package/lib/spatial-controls/spatial-observations-panel/spatial-observations-panel.component.d.ts +117 -0
- package/lib/spatial-controls/spatial-transcripts-panel/spatial-transcripts-panel.component.d.ts +142 -0
- package/lib/store/class-color.util.d.ts +35 -1
- package/lib/store/region-history.d.ts +66 -0
- package/lib/store/region-scope-cache.d.ts +63 -0
- package/lib/store/region-selection.d.ts +36 -0
- package/lib/store/region-store.service.d.ts +104 -112
- package/lib/store/visualizer-store.service.d.ts +22 -33
- package/lib/toast-outlets.d.ts +4 -3
- package/lib/toolbar/brush/brush-tool.service.d.ts +31 -98
- package/lib/toolbar/canvas-tools.d.ts +20 -0
- package/lib/toolbar/crop/slide-crop.d.ts +10 -4
- package/lib/toolbar/plot-type-selector/plot-type-selector.component.d.ts +38 -0
- package/lib/toolbar/region-tools/region-tool-buttons.d.ts +21 -0
- package/lib/toolbar/region-tools/region-tools.component.d.ts +60 -0
- package/lib/toolbar/segmentation/cell-segment-tool.service.d.ts +10 -14
- package/lib/toolbar/segmentation/cellpose-segmenter.service.d.ts +12 -2
- package/lib/toolbar/segmentation/onnx-sam-session.d.ts +22 -3
- package/lib/toolbar/segmentation/pending-calls.d.ts +31 -0
- package/lib/toolbar/segmentation/sam-model-registry.d.ts +9 -3
- package/lib/toolbar/segmentation/sam-onnx-core.d.ts +18 -5
- package/lib/toolbar/segmentation/sam-point-tool.service.d.ts +46 -32
- package/lib/toolbar/segmentation/sam-prompt.d.ts +7 -31
- package/lib/toolbar/segmentation/sam-session.service.d.ts +74 -0
- package/lib/toolbar/segmentation/sam-tool.service.d.ts +23 -30
- package/lib/toolbar/segmentation/segmentation-commit.d.ts +8 -0
- package/lib/toolbar/segmentation/segmentation-runner.d.ts +52 -0
- package/lib/toolbar/segmentation-tools/segmentation-tools.component.d.ts +87 -0
- package/lib/toolbar/stack-controls/stack-controls.component.d.ts +40 -0
- package/lib/toolbar/tool-kit/async-tool-status.d.ts +21 -0
- package/lib/toolbar/tool-kit/canvas-tool-manager.d.ts +36 -0
- package/lib/toolbar/tool-kit/canvas-tool.d.ts +86 -0
- package/lib/toolbar/tool-kit/frame-pixels.d.ts +45 -0
- package/lib/toolbar/tool-kit/mask-stroke-editor.d.ts +125 -0
- package/lib/toolbar/tool-kit/matrix-frame.d.ts +40 -0
- package/lib/toolbar/tool-kit/tool-overlay.d.ts +60 -0
- package/lib/toolbar/tool-kit/undo-gesture.d.ts +17 -0
- package/lib/toolbar/tool-slider/tool-slider.component.d.ts +33 -0
- package/lib/toolbar/toolbar-help-dialog/toolbar-help-dialog.component.d.ts +24 -0
- package/lib/toolbar/toolbar.component.d.ts +47 -83
- package/lib/toolbar/vertex-eraser/vertex-eraser-tool.service.d.ts +33 -40
- package/lib/toolbar/view-controls/view-controls.component.d.ts +54 -0
- package/lib/toolbar/wand/wand-region-grow.d.ts +49 -0
- package/lib/toolbar/wand/wand-tool.service.d.ts +39 -124
- package/lib/toolbar/wand/wand.service.d.ts +22 -116
- package/lib/toolbar/zoom-to-box/zoom-to-box-tool.service.d.ts +17 -37
- package/lib/util/mark-for-check.d.ts +11 -0
- package/lib/util/supersede.d.ts +53 -0
- package/lib/visualization.module.d.ts +18 -39
- package/lib/visualizer/floating-drag.directive.d.ts +30 -0
- package/lib/visualizer/region-actions.d.ts +54 -0
- package/lib/visualizer/region-load.d.ts +27 -0
- package/lib/visualizer/spatial-dataset-binder.d.ts +74 -0
- package/lib/visualizer/tool-modes.d.ts +49 -0
- package/lib/visualizer/viewer-shortcuts.d.ts +71 -0
- package/lib/visualizer/visualizer-context-menu.d.ts +55 -0
- package/lib/visualizer.component.d.ts +201 -447
- package/lib/workers/spatial-math-ops.d.ts +65 -0
- package/lib/workers/spatial-math-worker.d.ts +7 -0
- package/lib/workers/spatial-math.d.ts +74 -0
- package/package.json +12 -3
- package/src/lib/styles/_viz-icons-rules.scss +73 -0
- package/src/lib/styles/viz-icons.scss +14 -0
- package/esm2022/lib/implementations/napari-js/napari-axes-labels.mjs +0 -97
- package/esm2022/lib/implementations/napari-js/napari-navigator.mjs +0 -195
- package/esm2022/lib/implementations/napari-js/napari-scale-bar.mjs +0 -92
- package/fesm2022/jax-data-science-sci-image-visualizer-onnx-sam-session-BwP-A11m.mjs +0 -329
- package/fesm2022/jax-data-science-sci-image-visualizer-onnx-sam-session-BwP-A11m.mjs.map +0 -1
- package/lib/implementations/napari-js/napari-axes-labels.d.ts +0 -49
- package/lib/implementations/napari-js/napari-navigator.d.ts +0 -72
- package/lib/implementations/napari-js/napari-scale-bar.d.ts +0 -35
- package/src/lib/assets/cell-detection.svg +0 -37
- package/src/lib/assets/click.svg +0 -1
- package/src/lib/assets/colormap-luts.json +0 -1
- package/src/lib/assets/edit-selection-white.svg +0 -47
- package/src/lib/assets/icons/colormap-earth.png +0 -0
- package/src/lib/assets/icons/colormap-placeholder.png +0 -0
- package/src/lib/assets/icons/colormap-pubu.png +0 -0
- package/src/lib/assets/interactive-segmentation-cursor.svg +0 -1
- package/src/lib/assets/picture-segmentation.svg +0 -43
- package/src/lib/assets/test/download-379.svg +0 -1
- package/src/lib/assets/test/download-98.svg +0 -1
- package/src/lib/assets/test/json-1.svg +0 -1
- package/src/lib/assets/test/load-53.svg +0 -1
- package/src/lib/assets/test/mask-44.svg +0 -1
- package/src/lib/assets/test/mask-download-44.svg +0 -15
- package/src/lib/assets/test/mask-save-44.svg +0 -11
- package/src/lib/assets/test/overlay-1.svg +0 -1
- package/src/lib/assets/test/overlay-4.svg +0 -1
- package/src/lib/assets/test/region-26.svg +0 -1
- package/src/lib/assets/test/save-56.svg +0 -1
- package/src/lib/assets/test/upload-43.svg +0 -1
|
@@ -2,6 +2,8 @@ import { AfterViewInit, OnDestroy, OnInit } from '@angular/core';
|
|
|
2
2
|
import { IVisualizer, ISpatialControls } from '../../contracts/visualizer.contract';
|
|
3
3
|
import { SpatialEmbeddingMeta } from '../../contracts/spatial-dataset.contract';
|
|
4
4
|
import { SpatialColorBy } from '../../contracts/display-types';
|
|
5
|
+
import { EmbeddingComputeState } from '../../spatial/embedding-compute-coordinator';
|
|
6
|
+
import { ChartKindOption } from './chart-help';
|
|
5
7
|
import { OmicsChartKind } from '../../implementations/plotly/omics-trace-builders';
|
|
6
8
|
import * as i0 from "@angular/core";
|
|
7
9
|
/**
|
|
@@ -23,6 +25,10 @@ import * as i0 from "@angular/core";
|
|
|
23
25
|
* Depends only on {@link ISpatialControls} through the `VISUALIZER` contract
|
|
24
26
|
* token, like `SpatialControlsComponent`. Trace building lives in the pure
|
|
25
27
|
* `omics-trace-builders`; this component only moves data and owns the div.
|
|
28
|
+
*
|
|
29
|
+
* OnPush: its state lives in collaborators that change asynchronously (the data loads,
|
|
30
|
+
* the t-SNE run, the plot host), so the controls' streams, the run's state, every
|
|
31
|
+
* finished draw and every load start mark it for check.
|
|
26
32
|
*/
|
|
27
33
|
export declare class SpatialChartsComponent implements OnInit, AfterViewInit, OnDestroy {
|
|
28
34
|
private readonly viz;
|
|
@@ -35,15 +41,15 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
35
41
|
set active(on: boolean);
|
|
36
42
|
get active(): boolean;
|
|
37
43
|
private isActive;
|
|
38
|
-
/** Per-instance, for the same reason the visualizer's plot div is
|
|
39
|
-
* (`visualizer.component.ts`): two mounted charts sharing one DOM id means
|
|
40
|
-
* `getElementById` hands both of them the first element, so one instance draws
|
|
41
|
-
* into — or purges — the other's canvas. */
|
|
42
44
|
/** One increment per INSTANCE — a static initializer would run once per class and
|
|
43
45
|
* hand every instance the same id, which is the bug this id exists to avoid. Declared
|
|
44
46
|
* before the ids because field initializers run in order. */
|
|
45
47
|
private readonly seq;
|
|
46
|
-
|
|
48
|
+
/** Per-instance, for the same reason the visualizer's plot div is
|
|
49
|
+
* (`visualizer.component.ts`): two mounted charts sharing one DOM id means
|
|
50
|
+
* `getElementById` hands both of them the first element, so one instance draws
|
|
51
|
+
* into — or purges — the other's canvas. */
|
|
52
|
+
protected readonly chartDiv: string;
|
|
47
53
|
/**
|
|
48
54
|
* The div inside the detached window.
|
|
49
55
|
*
|
|
@@ -54,7 +60,7 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
54
60
|
* ONE is enough for every kind, because only the active kind is ever plotted. Detaching
|
|
55
61
|
* is remembered per kind, but at most one window is open at a time.
|
|
56
62
|
*/
|
|
57
|
-
readonly detachedDiv: string;
|
|
63
|
+
protected readonly detachedDiv: string;
|
|
58
64
|
/**
|
|
59
65
|
* Whether the chart is shown in its own window rather than inline.
|
|
60
66
|
*
|
|
@@ -67,93 +73,61 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
67
73
|
* charts beside the map, switching from the heatmap to the counts should swap what the
|
|
68
74
|
* window shows, not yank it back into the dialog and make them detach it again.
|
|
69
75
|
*/
|
|
70
|
-
detached: boolean;
|
|
71
|
-
private static readonly CONTINUOUS_KINDS;
|
|
72
|
-
private static readonly CATEGORICAL_KINDS;
|
|
73
|
-
/** Available whatever the map is coloured by: the heatmap's subject is a GENE
|
|
74
|
-
* LIST crossed with a grouping, not the active colour source. */
|
|
75
|
-
private static readonly ALWAYS_KINDS;
|
|
76
|
-
/**
|
|
77
|
-
* A t-SNE the dataset does not publish, offered so it can be computed here.
|
|
78
|
-
*
|
|
79
|
-
* A dropped-in `.h5ad` typically carries one UMAP and a PCA, and no t-SNE — the two
|
|
80
|
-
* views answer different questions, so having only one is a real gap. Computing it
|
|
81
|
-
* needs no expression data: t-SNE runs on the PCA scores, which is why this can happen
|
|
82
|
-
* in the browser at all while PCA cannot.
|
|
83
|
-
*/
|
|
84
|
-
private static readonly COMPUTABLE;
|
|
85
|
-
/** The menu suffix that says a click will start work; not part of the name. */
|
|
86
|
-
private static readonly COMPUTE_SUFFIX;
|
|
76
|
+
protected detached: boolean;
|
|
87
77
|
/**
|
|
88
|
-
* Largest dataset this will offer to embed in the browser
|
|
89
|
-
*
|
|
90
|
-
* t-SNE is O(N²) per iteration — vectorised on the GPU, but not approximated — so the
|
|
91
|
-
* cost is quadratic in observations. Measured end to end in Firefox on WebGPU: 2,688
|
|
92
|
-
* points took 95 s. That scales to roughly five and a half minutes at this threshold,
|
|
93
|
-
* and to about 76 minutes at seqFISH's 19,416, which was also measured offline.
|
|
94
|
-
*
|
|
95
|
-
* Past this the option is WITHDRAWN rather than offered with a warning. An hour-long
|
|
96
|
-
* job started from a button is not a choice a reader can meaningfully consent to in a
|
|
97
|
-
* dialog, and a t-SNE that large belongs in the offline pipeline, where it can run
|
|
98
|
-
* once and be served to everyone.
|
|
78
|
+
* Largest dataset this will offer to embed in the browser — see
|
|
79
|
+
* {@link BROWSER_TSNE_MAX_OBSERVATIONS}.
|
|
99
80
|
*/
|
|
100
81
|
static readonly BROWSER_TSNE_MAX_OBSERVATIONS = 5000;
|
|
101
|
-
/**
|
|
102
|
-
private
|
|
103
|
-
/** Coordinates computed in this browser, by name. Not persisted: a reload recomputes. */
|
|
104
|
-
private readonly computed;
|
|
105
|
-
/** The live run, when one is going. */
|
|
106
|
-
private computeRun;
|
|
107
|
-
/**
|
|
108
|
-
* Bumped by every dataset change and by teardown, so a computation in progress can tell
|
|
109
|
-
* that what it is computing is no longer what is on screen.
|
|
110
|
-
*
|
|
111
|
-
* A run is several awaits long — the PCA scores arrive over HTTP, then the worker takes
|
|
112
|
-
* a minute or more — and the dataset can change at any of them, including BEFORE
|
|
113
|
-
* `computeRun` exists to be terminated. Without a token, the scores fetched for one
|
|
114
|
-
* dataset get embedded and drawn over another's observations: a plot of two datasets at
|
|
115
|
-
* once, which reads as a strange-looking t-SNE rather than as a bug.
|
|
116
|
-
*/
|
|
117
|
-
private computeToken;
|
|
82
|
+
/** The t-SNE computed in this browser: what to offer, the run, its progress, its results. */
|
|
83
|
+
private readonly compute;
|
|
118
84
|
/** 0..1 while running, or null before the first report. Drives the progress bar. */
|
|
119
|
-
computeFraction: number | null;
|
|
85
|
+
get computeFraction(): number | null;
|
|
120
86
|
/** Which backend the worker got — 'webgpu', 'wasm' or 'cpu'. Shown while running. */
|
|
121
|
-
computeBackend: string | null;
|
|
122
|
-
computeMessage: string | null;
|
|
123
|
-
computeError: string | null;
|
|
87
|
+
get computeBackend(): string | null;
|
|
88
|
+
get computeMessage(): string | null;
|
|
89
|
+
get computeError(): string | null;
|
|
90
|
+
/** Where a computation stands, for the embedding controls. */
|
|
91
|
+
protected get computeState(): EmbeddingComputeState;
|
|
124
92
|
/** True when a t-SNE is missing but the dataset is too big to embed here. */
|
|
125
|
-
tsneTooLarge: boolean;
|
|
126
|
-
/** Observations in the live dataset, kept for the cost estimate. */
|
|
127
|
-
private observationCount;
|
|
128
|
-
/** Offered only when the dataset publishes an embedding to draw. */
|
|
129
|
-
private static readonly EMBEDDING_KINDS;
|
|
93
|
+
protected get tsneTooLarge(): boolean;
|
|
130
94
|
/** The kinds the ACTIVE subject can be drawn as. A category code is a label,
|
|
131
95
|
* not a magnitude, so a histogram of it would be meaningless — what a
|
|
132
|
-
* categorical column has is a frequency distribution.
|
|
133
|
-
|
|
96
|
+
* categorical column has is a frequency distribution.
|
|
97
|
+
*
|
|
98
|
+
* Bound to a `p-selectButton`, so the SAME array is returned until what it is built
|
|
99
|
+
* from changes: a fresh array per change-detection pass makes PrimeNG re-render the
|
|
100
|
+
* buttons, and a button re-rendered under the pointer swallows the click. */
|
|
101
|
+
protected get kindOptions(): ChartKindOption[];
|
|
102
|
+
private kindOptionsMemo;
|
|
103
|
+
protected controls: ISpatialControls | null;
|
|
104
|
+
protected kind: OmicsChartKind;
|
|
105
|
+
/** The data charted, and its loading — see {@link ChartDataModel}. */
|
|
106
|
+
private readonly data;
|
|
107
|
+
/** Embeddings the dataset offers, and which of them is drawn. */
|
|
108
|
+
protected get embeddings(): SpatialEmbeddingMeta[];
|
|
109
|
+
protected get embedding(): SpatialEmbeddingMeta | null;
|
|
110
|
+
/** Genes the heatmap's rows are. */
|
|
111
|
+
protected get heatmapGenes(): string[];
|
|
112
|
+
/** The heatmap gene picker's options. */
|
|
113
|
+
protected get geneOptions(): {
|
|
134
114
|
label: string;
|
|
135
|
-
value:
|
|
115
|
+
value: string;
|
|
136
116
|
}[];
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
/**
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
/**
|
|
147
|
-
|
|
148
|
-
*
|
|
149
|
-
* Local rather than in `SpatialViewState`, matching how the chart KIND is
|
|
150
|
-
* held: this is what the panel is charting, not what the map is drawing, and
|
|
151
|
-
* the renderer has no use for it.
|
|
152
|
-
*/
|
|
153
|
-
heatmapGenes: string[];
|
|
117
|
+
/** Categorical column the violin/box splits by; null = one trace for all. */
|
|
118
|
+
protected get groupBy(): string | null;
|
|
119
|
+
protected get groupOptions(): {
|
|
120
|
+
label: string;
|
|
121
|
+
value: string | null;
|
|
122
|
+
}[];
|
|
123
|
+
/** Set when the active colour source cannot be charted, for an inline hint. */
|
|
124
|
+
protected get notice(): string | null;
|
|
125
|
+
protected set notice(text: string | null);
|
|
126
|
+
/** A load is in flight. */
|
|
127
|
+
protected get busy(): boolean;
|
|
154
128
|
/** Z-score each gene across the groups. On by default: without it one loud
|
|
155
129
|
* gene saturates the scale and the rest of the panel reads as blank. */
|
|
156
|
-
heatmapZScore: boolean;
|
|
130
|
+
protected heatmapZScore: boolean;
|
|
157
131
|
/** Past this many selected cells the per-cell view is a texture, not a
|
|
158
132
|
* readable panel, so the columns go back to being classes. */
|
|
159
133
|
private static readonly HEATMAP_CELL_COLUMNS;
|
|
@@ -169,57 +143,24 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
169
143
|
private static readonly HEATMAP_MAX_COLUMNS;
|
|
170
144
|
/** Columns the cap dropped from the last render, for the note. */
|
|
171
145
|
private heatmapHidden;
|
|
172
|
-
geneOptions: {
|
|
173
|
-
label: string;
|
|
174
|
-
value: string;
|
|
175
|
-
}[];
|
|
176
|
-
/** Every gene the dataset inlined. `geneOptions` is only ever the best few hundred of
|
|
177
|
-
* these — see `gene-search.ts` for why a whole-transcriptome list cannot be handed to
|
|
178
|
-
* the control whole. */
|
|
179
|
-
private geneNames;
|
|
180
|
-
/** What is typed in the picker's filter box, so the options can be rebuilt when the
|
|
181
|
-
* selection changes without losing the query. */
|
|
182
|
-
private geneQuery;
|
|
183
|
-
/** Fetched vectors by gene name, so adding a fourth gene does not refetch the
|
|
184
|
-
* first three — each is a full per-observation Float32Array. */
|
|
185
|
-
private readonly geneCache;
|
|
186
|
-
/** Categorical column the violin/box splits by; null = one trace for all. */
|
|
187
|
-
groupBy: string | null;
|
|
188
|
-
groupOptions: {
|
|
189
|
-
label: string;
|
|
190
|
-
value: string | null;
|
|
191
|
-
}[];
|
|
192
146
|
/** What the map is coloured by — the chart's subject. */
|
|
193
147
|
colorBy: SpatialColorBy | null;
|
|
194
|
-
selectionCount: number;
|
|
195
|
-
/** Set when the active colour source cannot be charted, for an inline hint. */
|
|
196
|
-
notice: string | null;
|
|
197
|
-
busy: boolean;
|
|
148
|
+
protected selectionCount: number;
|
|
198
149
|
private view;
|
|
199
150
|
private selection;
|
|
200
|
-
private values;
|
|
201
|
-
/** Set instead of `values` when the colour source is a categorical column: its
|
|
202
|
-
* distribution is counts per category, not a histogram of its codes. */
|
|
203
|
-
private categorical;
|
|
204
|
-
private grouping;
|
|
205
|
-
/** Guards the async value fetch: a fast colour-source change can resolve out
|
|
206
|
-
* of order, and a stale vector would be charted against the new label. */
|
|
207
|
-
private token;
|
|
208
|
-
/** The same guard for the grouping fetch, which the user can change as fast. */
|
|
209
|
-
private groupToken;
|
|
210
151
|
/** Whether the first view emission has been handled. */
|
|
211
152
|
private primed;
|
|
212
|
-
private readonly
|
|
153
|
+
private readonly destroyRef;
|
|
154
|
+
private readonly cdr;
|
|
155
|
+
private readonly zone;
|
|
156
|
+
/** Re-render this OnPush view, re-entering the zone when the change came from outside it. */
|
|
157
|
+
private changed;
|
|
213
158
|
constructor(viz: IVisualizer);
|
|
214
159
|
ngOnInit(): void;
|
|
215
|
-
/**
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
* to their content — one band per bar, per gene row — while the distribution
|
|
220
|
-
* kinds want to fill whatever height they are given.
|
|
221
|
-
*/
|
|
222
|
-
private drawnHeight;
|
|
160
|
+
/** Latest wins among heatmap draws, whose matrix may be computed in a worker. */
|
|
161
|
+
private readonly heatmapRender;
|
|
162
|
+
/** Plotly I/O for both the inline and the detached div. */
|
|
163
|
+
private readonly plot;
|
|
223
164
|
/**
|
|
224
165
|
* Re-fit the plot to the panel's current width.
|
|
225
166
|
*
|
|
@@ -228,43 +169,28 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
228
169
|
* resizes only, so dragging a dialog edge reaches it through nothing at all.
|
|
229
170
|
*/
|
|
230
171
|
resize(): void;
|
|
231
|
-
/**
|
|
232
|
-
*
|
|
233
|
-
*
|
|
234
|
-
* Shared by the panel and the detached window because the rule is the same and getting
|
|
235
|
-
* it wrong is invisible until it is not: `autosize` takes BOTH dimensions from the
|
|
236
|
-
* container, which is right only where the layout did not fix its own height. Measured:
|
|
237
|
-
* autosizing a layout with an explicit height of 500 replaced it with the container's
|
|
238
|
-
* 400. The counts and heatmap layouts size themselves to their row count, so the
|
|
239
|
-
* window resize has to set the width ALONE for them and let the height stand.
|
|
240
|
-
*/
|
|
241
|
-
private refit;
|
|
172
|
+
/** Stops the t-SNE run and heatmap worker and frees both plots; the streams end
|
|
173
|
+
* through `takeUntilDestroyed`. */
|
|
242
174
|
ngOnDestroy(): void;
|
|
243
175
|
ngAfterViewInit(): void;
|
|
244
|
-
onKind(kind: OmicsChartKind): void;
|
|
176
|
+
protected onKind(kind: OmicsChartKind): void;
|
|
245
177
|
/**
|
|
246
178
|
* The grouping the heatmap's columns come from, defaulting rather than
|
|
247
179
|
* demanding one: a heatmap with no columns is not a chart, and "No grouping"
|
|
248
180
|
* is a sensible answer for a violin but not for this.
|
|
249
181
|
*/
|
|
250
182
|
private ensureHeatmapGrouping;
|
|
251
|
-
onHeatmapZScore(on: boolean): void;
|
|
183
|
+
protected onHeatmapZScore(on: boolean): void;
|
|
252
184
|
/** What the heatmap is currently showing, said plainly. */
|
|
253
|
-
get heatmapNote(): string;
|
|
185
|
+
protected get heatmapNote(): string;
|
|
254
186
|
/** Gene rows for the heatmap. */
|
|
255
|
-
onHeatmapGenes(names: string[]): Promise<void>;
|
|
256
|
-
/**
|
|
257
|
-
* Fetch any gene the heatmap needs and does not already hold.
|
|
258
|
-
*
|
|
259
|
-
* Sequenced on the same token the colour-source load uses: each vector is a
|
|
260
|
-
* separate request, and a slower one must not paint rows for a gene list the
|
|
261
|
-
* user has already moved on from.
|
|
262
|
-
*/
|
|
187
|
+
protected onHeatmapGenes(names: string[]): Promise<void>;
|
|
188
|
+
/** Fetch any gene the heatmap needs and does not already hold. */
|
|
263
189
|
private loadHeatmapGenes;
|
|
264
|
-
onGroupBy(name: string | null): Promise<void>;
|
|
190
|
+
protected onGroupBy(name: string | null): Promise<void>;
|
|
265
191
|
/** True when the current kind would read better with a grouping chosen. */
|
|
266
|
-
get suggestsGrouping(): boolean;
|
|
267
|
-
get subject(): string;
|
|
192
|
+
protected get suggestsGrouping(): boolean;
|
|
193
|
+
protected get subject(): string;
|
|
268
194
|
/** Fetch the active colour source's vector, then draw. */
|
|
269
195
|
private reload;
|
|
270
196
|
/**
|
|
@@ -273,42 +199,12 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
273
199
|
* Answers what the map cannot: the map says WHERE a population sits, this says which
|
|
274
200
|
* populations there are and how close they are in expression.
|
|
275
201
|
*
|
|
276
|
-
* Linked to the map without asking for anything: it reuses
|
|
202
|
+
* Linked to the map without asking for anything: it reuses the loaded categories, the same
|
|
277
203
|
* loaded colouring the counts chart draws from, so the two cannot disagree about what a
|
|
278
204
|
* colour means and no second fetch happens. A selection dims the rest rather than
|
|
279
205
|
* dropping it — the embedding's shape is the context that makes a selection legible.
|
|
280
206
|
*/
|
|
281
207
|
private renderEmbedding;
|
|
282
|
-
/**
|
|
283
|
-
* Turn a lasso in the embedding into a selection of observations.
|
|
284
|
-
*
|
|
285
|
-
* This is what makes two views of one dataset worth having side by side: draw round a
|
|
286
|
-
* cluster here and those cells light up on the tissue, because every view reads the
|
|
287
|
-
* same mask.
|
|
288
|
-
*
|
|
289
|
-
* Bound after each draw, and the previous listener removed first: `Plotly.react`
|
|
290
|
-
* preserves handlers, so re-binding without removing would fire the selection once per
|
|
291
|
-
* redraw the plot had ever had.
|
|
292
|
-
*/
|
|
293
|
-
private bindEmbeddingSelection;
|
|
294
|
-
/**
|
|
295
|
-
* Drop the embedding's selection handlers from a div another kind is about to use.
|
|
296
|
-
*
|
|
297
|
-
* The detached window outlives any one kind — switching tabs swaps its content and
|
|
298
|
-
* keeps the div — so without this the lasso handlers bound for a UMAP stay live under
|
|
299
|
-
* the counts plot that replaces it. `plotly_deselect` fires on a plain click in ANY
|
|
300
|
-
* Plotly chart, so the first click on a bar would silently clear the map's selection.
|
|
301
|
-
*/
|
|
302
|
-
private unbindEmbeddingSelection;
|
|
303
|
-
/**
|
|
304
|
-
* The view the user has set up on the live plot, to carry across a redraw.
|
|
305
|
-
*
|
|
306
|
-
* `Plotly.react` resets a 3D scene camera and any zoomed 2D range unless the layout
|
|
307
|
-
* carries them, so selecting a category or recolouring would throw away an orientation
|
|
308
|
-
* that took work to find. Rotating a cloud to see a structure and losing it on the next
|
|
309
|
-
* click makes the plot useless for what it is for.
|
|
310
|
-
*/
|
|
311
|
-
private liveView;
|
|
312
208
|
/**
|
|
313
209
|
* Whether the plot on screen fixed its own height.
|
|
314
210
|
*
|
|
@@ -317,7 +213,7 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
317
213
|
* embedding fixes no height and fills the window instead. The template needs to know
|
|
318
214
|
* which, because the two want opposite `flex` and `overflow`.
|
|
319
215
|
*/
|
|
320
|
-
get hasFixedHeight(): boolean;
|
|
216
|
+
protected get hasFixedHeight(): boolean;
|
|
321
217
|
/** Where the active kind draws: its own window, or the shared chart div. */
|
|
322
218
|
get plotTarget(): string;
|
|
323
219
|
/**
|
|
@@ -326,7 +222,7 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
326
222
|
* The embedding names the embedding rather than the tab, because "Embedding" beside a
|
|
327
223
|
* window drawing a t-SNE says less than "t-SNE" does.
|
|
328
224
|
*/
|
|
329
|
-
get detachedTitle(): string;
|
|
225
|
+
protected get detachedTitle(): string;
|
|
330
226
|
/**
|
|
331
227
|
* Move the active kind between its own window and the panel.
|
|
332
228
|
*
|
|
@@ -334,97 +230,42 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
334
230
|
* behind in a div that Angular then removes leaks its WebGL context — and if the div
|
|
335
231
|
* comes back, react would resize a plot whose data belongs to the other place.
|
|
336
232
|
*/
|
|
337
|
-
toggleDetached(): void;
|
|
233
|
+
protected toggleDetached(): void;
|
|
338
234
|
/** The detached window is up and its div exists — now the plot can be drawn into it. */
|
|
339
|
-
onDetachedWindowShown(): void;
|
|
235
|
+
protected onDetachedWindowShown(): void;
|
|
340
236
|
/** Re-fit the detached window's plot after it is resized. */
|
|
341
|
-
onDetachedResizeEnd(): void;
|
|
342
|
-
/**
|
|
343
|
-
* Rebuild the visible options: the best matches for what is typed, plus what is chosen.
|
|
344
|
-
*
|
|
345
|
-
* A capped multi-select that drops its own selections cannot resolve their labels, and
|
|
346
|
-
* the model loses them on the next change — the chips vanish for no reason the user
|
|
347
|
-
* can see.
|
|
348
|
-
*/
|
|
349
|
-
private refreshGeneOptions;
|
|
237
|
+
protected onDetachedResizeEnd(): void;
|
|
350
238
|
/** The gene picker's filter box changed: search the resident names, show the best. */
|
|
351
|
-
onGeneFilter(query: string): void;
|
|
352
|
-
/**
|
|
353
|
-
* Roughly how long a run will take, in seconds, from the measured anchor.
|
|
354
|
-
*
|
|
355
|
-
* Shown before the click. A progress bar tells you a job is going; only an estimate
|
|
356
|
-
* tells you whether to start it.
|
|
357
|
-
*/
|
|
239
|
+
protected onGeneFilter(query: string): void;
|
|
240
|
+
/** Roughly how long a run will take, in seconds, from the measured anchor. */
|
|
358
241
|
get computeEstimateSeconds(): number;
|
|
359
242
|
/** That estimate as something to put on a button. */
|
|
360
|
-
get computeEstimateLabel(): string;
|
|
243
|
+
protected get computeEstimateLabel(): string;
|
|
361
244
|
/** Why the option is absent, when a dataset is past the threshold. */
|
|
362
|
-
get tsneTooLargeNote(): string;
|
|
245
|
+
protected get tsneTooLargeNote(): string;
|
|
363
246
|
/** Whether the selected embedding is one this browser would have to compute. */
|
|
364
|
-
get isComputable(): boolean;
|
|
247
|
+
protected get isComputable(): boolean;
|
|
365
248
|
/** Whether it has already been computed in this session. */
|
|
366
|
-
get isComputed(): boolean;
|
|
367
|
-
get isComputing(): boolean;
|
|
368
|
-
/**
|
|
369
|
-
|
|
370
|
-
*
|
|
371
|
-
* The PCA scores come from the port as an ordinary embedding — the server derives them,
|
|
372
|
-
* because PCA needs the whole expression matrix (185 MB for a Visium dataset) while
|
|
373
|
-
* t-SNE needs only the scores (0.51 MB). Sending the matrix to the browser to save a
|
|
374
|
-
* few seconds of arithmetic would be a far slower answer.
|
|
375
|
-
*/
|
|
376
|
-
computeEmbedding(): Promise<void>;
|
|
249
|
+
protected get isComputed(): boolean;
|
|
250
|
+
protected get isComputing(): boolean;
|
|
251
|
+
/** Compute the selected embedding here, in a worker, then draw it. */
|
|
252
|
+
protected computeEmbedding(): Promise<void>;
|
|
377
253
|
/** Stop a run. It settles shortly after, leaving no embedding. */
|
|
378
|
-
cancelCompute(): void;
|
|
379
|
-
/**
|
|
380
|
-
* Drop any computation in progress, because what it is computing no longer applies.
|
|
381
|
-
*
|
|
382
|
-
* Distinct from {@link cancelCompute}, which is the user's Cancel and asks the worker to
|
|
383
|
-
* stop politely. This one does not wait: the run is settled and the worker killed, so a
|
|
384
|
-
* dataset switch or a teardown cannot leave a t-SNE grinding on in the background over
|
|
385
|
-
* observations nothing is showing any more.
|
|
386
|
-
*/
|
|
387
|
-
private abandonCompute;
|
|
388
|
-
/**
|
|
389
|
-
* The dataset's PCA, as row-major scores.
|
|
390
|
-
*
|
|
391
|
-
* Assembled from whichever PCA the source offers, widest first — a 3-D one gives t-SNE
|
|
392
|
-
* three components instead of two for the same request.
|
|
393
|
-
*/
|
|
394
|
-
private loadPcaScores;
|
|
254
|
+
protected cancelCompute(): void;
|
|
395
255
|
/** Which embedding to draw, when the dataset publishes more than one. */
|
|
396
|
-
onEmbedding(name: string): void;
|
|
397
|
-
/**
|
|
398
|
-
|
|
399
|
-
*
|
|
400
|
-
* Shown on hover from a `?` beside the tabs. Each of these plots answers a different
|
|
401
|
-
* question and two of them are routinely over-read — a UMAP's distances and a heatmap's
|
|
402
|
-
* unscaled colours — so the caveat is part of the explanation rather than a footnote.
|
|
403
|
-
*
|
|
404
|
-
* HTML, because the tooltip renders with `[escape]="false"`: a paragraph and a caveat
|
|
405
|
-
* read as two thoughts, and a single run-on line is skipped rather than read.
|
|
406
|
-
*/
|
|
407
|
-
get kindHelp(): string;
|
|
408
|
-
/**
|
|
409
|
-
* What the embedding on screen is, and how far its geometry can be trusted.
|
|
410
|
-
*
|
|
411
|
-
* Per METHOD, because that is the part people get wrong: a PCA's axes are ordered and
|
|
412
|
-
* measurable while a UMAP's are neither, and the same picture read the two ways supports
|
|
413
|
-
* opposite conclusions.
|
|
414
|
-
*/
|
|
415
|
-
private get embeddingHelp();
|
|
256
|
+
protected onEmbedding(name: string): void;
|
|
257
|
+
/** What the chart on screen shows, and what it cannot be read for — see {@link kindHelp}. */
|
|
258
|
+
protected get kindHelp(): string;
|
|
416
259
|
/** What the embedding view is showing, said plainly. */
|
|
417
|
-
get embeddingNote(): string;
|
|
260
|
+
protected get embeddingNote(): string;
|
|
261
|
+
/** Purge the ACTIVE target: purging the inline div while detached would leave the window
|
|
262
|
+
* showing a plot the component believes it has cleared. */
|
|
418
263
|
private purgePlot;
|
|
419
|
-
/**
|
|
420
|
-
* Draw, remembering whether this layout fixed its own height.
|
|
421
|
-
*
|
|
422
|
-
* The layout builders return `unknown` on purpose — they keep Plotly's layout
|
|
423
|
-
* types out of the pure module — so the height is read back by narrowing
|
|
424
|
-
* rather than declared. `height` is Plotly's own key, not ours.
|
|
425
|
-
*/
|
|
264
|
+
/** Draw into the active target. */
|
|
426
265
|
private draw;
|
|
266
|
+
/** Draw the active kind, then re-render the panel around it (notices, height, notes). */
|
|
427
267
|
private render;
|
|
268
|
+
private renderChart;
|
|
428
269
|
/**
|
|
429
270
|
* Genes × groups mean expression.
|
|
430
271
|
*
|
|
@@ -435,5 +276,5 @@ export declare class SpatialChartsComponent implements OnInit, AfterViewInit, On
|
|
|
435
276
|
*/
|
|
436
277
|
private renderHeatmap;
|
|
437
278
|
static ɵfac: i0.ɵɵFactoryDeclaration<SpatialChartsComponent, never>;
|
|
438
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SpatialChartsComponent, "spatial-charts", never, { "active": { "alias": "active"; "required": false; }; }, {}, never, never,
|
|
279
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SpatialChartsComponent, "spatial-charts", never, { "active": { "alias": "active"; "required": false; }; }, {}, never, never, true, never>;
|
|
439
280
|
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import type { SpatialEmbeddingMeta } from '../../../contracts/spatial-dataset.contract';
|
|
3
|
+
import type { EmbeddingComputeState } from '../../../spatial/embedding-compute-coordinator';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
/**
|
|
6
|
+
* The row under the chart tabs: which embedding to draw, computing a t-SNE the dataset
|
|
7
|
+
* does not publish (with its estimate, progress, Cancel and errors), and detaching the
|
|
8
|
+
* chart into its own window — which applies to every kind.
|
|
9
|
+
*
|
|
10
|
+
* Presentational: the charts panel owns the embeddings, the computation and the window.
|
|
11
|
+
*/
|
|
12
|
+
export declare class SpatialEmbeddingControlsComponent {
|
|
13
|
+
/** Whether the Embedding tab is the one on screen. */
|
|
14
|
+
isEmbedding: boolean;
|
|
15
|
+
/** The embeddings the dataset offers (plus one to compute, when offered). */
|
|
16
|
+
embeddings: SpatialEmbeddingMeta[];
|
|
17
|
+
/** The embedding drawn, or null. */
|
|
18
|
+
embedding: SpatialEmbeddingMeta | null;
|
|
19
|
+
/** The selected embedding is one this browser would have to compute… */
|
|
20
|
+
computable: boolean;
|
|
21
|
+
/** …and it has been, this session. */
|
|
22
|
+
computed: boolean;
|
|
23
|
+
/** A computation is running. */
|
|
24
|
+
running: boolean;
|
|
25
|
+
/** Where a computation stands: its progress, backend, message and error. */
|
|
26
|
+
state: EmbeddingComputeState;
|
|
27
|
+
/** The run's estimated duration, for the Compute button. */
|
|
28
|
+
estimateLabel: string;
|
|
29
|
+
/** Why a t-SNE is not offered, when the dataset is too big to embed here; else null. */
|
|
30
|
+
tooLargeNote: string | null;
|
|
31
|
+
/** Whether the chart is in its own window. */
|
|
32
|
+
detached: boolean;
|
|
33
|
+
/** Another embedding was picked (its name). */
|
|
34
|
+
readonly embeddingChange: EventEmitter<string>;
|
|
35
|
+
/** Compute the selected embedding in this browser. */
|
|
36
|
+
readonly compute: EventEmitter<void>;
|
|
37
|
+
/** Stop the running computation. */
|
|
38
|
+
readonly cancel: EventEmitter<void>;
|
|
39
|
+
/** Move the chart into its own window, or back into the panel. */
|
|
40
|
+
readonly detachedToggle: EventEmitter<void>;
|
|
41
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SpatialEmbeddingControlsComponent, never>;
|
|
42
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SpatialEmbeddingControlsComponent, "spatial-embedding-controls", never, { "isEmbedding": { "alias": "isEmbedding"; "required": false; }; "embeddings": { "alias": "embeddings"; "required": false; }; "embedding": { "alias": "embedding"; "required": false; }; "computable": { "alias": "computable"; "required": false; }; "computed": { "alias": "computed"; "required": false; }; "running": { "alias": "running"; "required": false; }; "state": { "alias": "state"; "required": false; }; "estimateLabel": { "alias": "estimateLabel"; "required": false; }; "tooLargeNote": { "alias": "tooLargeNote"; "required": false; }; "detached": { "alias": "detached"; "required": false; }; }, { "embeddingChange": "embeddingChange"; "compute": "compute"; "cancel": "cancel"; "detachedToggle": "detachedToggle"; }, never, never, true, never>;
|
|
43
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { EventEmitter } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* The heatmap's own controls: the genes its rows are (a filterable multi-select over the
|
|
5
|
+
* dataset's names) and whether each gene is z-scored across the columns.
|
|
6
|
+
*
|
|
7
|
+
* Presentational: the charts panel owns the gene list and the vectors behind it.
|
|
8
|
+
*/
|
|
9
|
+
export declare class SpatialHeatmapControlsComponent {
|
|
10
|
+
/** The picker's options: the best matches for the filter, plus the genes chosen. */
|
|
11
|
+
geneOptions: {
|
|
12
|
+
label: string;
|
|
13
|
+
value: string;
|
|
14
|
+
}[];
|
|
15
|
+
/** The genes the rows are. */
|
|
16
|
+
genes: string[];
|
|
17
|
+
/** Each gene is z-scored across the groups. */
|
|
18
|
+
zScore: boolean;
|
|
19
|
+
/** The genes picked for the rows. */
|
|
20
|
+
readonly genesChange: EventEmitter<string[]>;
|
|
21
|
+
/** What is typed in the picker's filter box. */
|
|
22
|
+
readonly filterChange: EventEmitter<string>;
|
|
23
|
+
/** The z-score toggle changed. */
|
|
24
|
+
readonly zScoreChange: EventEmitter<boolean>;
|
|
25
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SpatialHeatmapControlsComponent, never>;
|
|
26
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SpatialHeatmapControlsComponent, "spatial-heatmap-controls", never, { "geneOptions": { "alias": "geneOptions"; "required": false; }; "genes": { "alias": "genes"; "required": false; }; "zScore": { "alias": "zScore"; "required": false; }; }, { "genesChange": "genesChange"; "filterChange": "filterChange"; "zScoreChange": "zScoreChange"; }, never, never, true, never>;
|
|
27
|
+
}
|