TissUUmaps 3: Improvements in interactive visualization, exploration, and quality assessment of large-scale spatial omics data

Background and objectives Spatially resolved techniques for exploring the molecular landscape of tissue samples, such as spatial transcriptomics, often result in millions of data points and images too large to view on a regular desktop computer, limiting the possibilities in visual interactive data exploration. TissUUmaps is a free, open-source browser-based tool for GPU-accelerated visualization and interactive exploration of 107+ data points overlaying tissue samples. Methods Herein we describe how TissUUmaps 3 provides instant multiresolution image viewing and can be customized, shared, and also integrated into Jupyter Notebooks. We introduce new modules where users can visualize markers and regions, explore spatial statistics, perform quantitative analyses of tissue morphology, and assess the quality of decoding in situ transcriptomics data. Results We show that thanks to targeted optimizations the time and cost associated with interactive data exploration were reduced, enabling TissUUmaps 3 to handle the scale of today's spatial transcriptomics methods. Conclusion TissUUmaps 3 provides significantly improved performance for large multiplex datasets as compared to previous versions. We envision TissUUmaps to contribute to broader dissemination and flexible sharing of largescale spatial omics data.


Introduction
Over the past few years, a variety of spatial transcriptomic (ST) techniques has emerged [48], leading to scientific advances in many different areas [6]. These techniques can be classified into two groups: imaging-based ST (IST), which directly sequences individual mRNA molecules [18,22,26,27,31,62,63], and sequencing-based ST (SST), which uses micro-arrays or fluorescent beads to capture and sequence mRNA molecules with maintained information on spatial location [51,56,57]. The techniques have their respective advantages and disadvantages, but they share a common difficulty: the vast number of targeted molecules and the wide range of spatial scales makes visual exploration difficult. For example, a single IST experiment can produce millions of spatial markers for various mRNA molecules. Molecular patterns on a micrometer scale define cell types while the centimeter scale is needed for identifying tissue-level structures. However, patterns appearing at different scales are difficult to interpret using only one resolution and instead require interactive multi-resolution viewing. Moreover, interactive visualization of large quantities of markers is computationally challenging. Sub-sampling information, as is common in mapviewing functions such as Google Maps, could be an option, but may be risky: Sub-sampling sparse signals representing the presence of e.g. a virus, or a rare cell type, may lead to loss of very relevant information.
Additionally, the large number of different molecules targeted in parallel poses practical and computational challenges when it comes to interactive visualization. A single IST experiment can target up to hundreds of different mRNA species. Exploring patterns in such high-dimensional spaces is fundamentally difficult. A common approach to make the data more manageable is to compute the composition of molecules within small regional areas, such as segmented cells or spatial bins, to generate high-dimensional feature vectors [42,43,46,49]. These features can then be projected into a lower-dimensional feature space using techniques such as UMAP [10] or t-SNE [60] to reveal different cell types or spatial domains. Unlike single-cell RNA sequencing data, ST data includes information about the location of RNAs within the imaged tissue. To fully make use of this information, visualization must simultaneously show the detected RNAs in their spatial context as well as their location in feature space. Here, region-based markers, such as polygons, can be used to visualize segmented cells. Regions may also be manually or automatically drawn to represent, e.g., tumors or specific anatomical structures.
Drawing biological or biomedical conclusions from ST data often requires cross-disciplinary expertise but sharing complex datasets is tedious as it often requires wrangling with customized file formats, software, and transferring of large datasets. In these cases, interactive solutions that are hostable as online resources are practical, as the data is readily visualized in a web browser, and all that has to be shared is a web link. Interactive visualization plays a key role not only for those wishing to understand the underlying biology but also for those developing these technologies and methods for analyzing data produced by such technologies. During the past years, several new methods for analyzing ST data have emerged. For example, tools for cell segmentation, identification of spatially variable genes, cell typing, data imputation, and analyses of cellcell interactions, as summarized in Refs. [19,23]. A deeper biological understanding of the results produced by these methods can be done with the help of visual inspection. Additionally, limitations in available ground truth make methods' quality control by visual inspection of raw data in relation to analysis results crucial.
In conclusion, the complexity and scale of ST data make interactive visualization essential, but practically difficult. We stipulate that a good tool for visualizing ST data should be able to: Provide multi-resolution viewing, of gigapixel-sized images, in a manner that allows the user to flexibly view and responsively interact with the data across multiple scales. Here, a pyramidal image format is desirable as it dramatically reduces the memory requirement.
Display large quantities (millions) of markers and regions of various types and with adjustable size, shape, and color. Display features and their spatial location in such a way that the user can simultaneously and interactively explore them in terms of spatial location and similarity.
Be hosted, such that interactive visualizations can conveniently be shared with the scientific community as online resources. Be easy to use in terms of installation and use by a wide variety of users and systems, without expensive and costly data transfer.

Related work
There are several tools available for the interactive exploration of omics data, particularly with the increasing interest in ST. However, many of these tools are designed only for specific techniques. For example, STViewer [39], Spacemake [59], and 10x Genomic's Loupe Browser [5] are all effective for exploring SST data but are not necessarily suitable for more general usage.
Viewers such as CellXGene [36], Cirrocumulus [3], and the Giotto viewer [17] are designed for the exploration of single-cell genomics and work on data where molecules have been aggregated into single-cell features. Although they provide interactive interfaces for the exploration of single-cell features in lower dimensional UMAP or t-SNE spaces, they lack functionalities for viewing individual molecular markers as well as displaying multi-layered image data.
Cytomine [32] and Visilab Viewer [30] allow the user to share large-scale interactive visualizations of gigapixel-sized images over the internet, enabling online collaboratory exploration and annotation. Their intended usage is for collaborative analysis of histopathological image data. As such, they lack functionalities for displaying markers and features, which is crucial for exploring ST data.
Although general-purpose viewers like matplotlib [25], BigDataViewer [47], QuPath [9], and Napari [53] are useful for displaying markers and images, they need customization to allow interactive exploration. Furthermore, unless they incorporate GPU rendering or adaptive image loading through pyramidal image formats, the image size and number of markers that can be displayed will be limited by the hardware's CPU and RAM capabilities.
Vizgen's end-to-end IST platform MERSCOPE comes with a proprietary and commercial web-viewer for interactive visualization of IST data. Using adaptive sub-sampling it can display hundreds of millions of markers on largescale image data. However, it is strictly limited to IST data and does not allow the user to explore single-cell features in, e.g., lower-dimensional feature spaces.
The previously published TissUUmaps 1 [54] enabled interactive visualization of molecular marks on top of gigapixel-sized images. To reduce the time needed for rendering the display, markers were sub-sampled at different zoom levels. Although this improved the performance of the software, rare molecular patterns could potentially be missed. Moreover, the software was designed to be hosted on a web server, and not used directly within analysis pipelines. As such, it lacked certain usability features. For instance, it required the user to manually convert image data into a pyramidal format and configure paths to image and marker data, thereby making the software less accessible for non-programmers.
Most closely related to TissUUmaps is Vitessce [28]. Vitessce provides an extensive framework for creating and customizing interactive figures with regard to the exploration of ST data. The framework allows the user to display millions of transcripts on top of multi-scale image data, as well as display regions and single cell-feature embedding, thereby making it a powerful tool for the exploration of ST data. The framework can also be hosted on a web platform, making it easy to share interactive visualizations over the internet. However, the framework requires the user to programmatically set up the graphical user interface and configure figures by coding, making Vitessce less accessible for the non-programmer.

Our contribution
Summarizing the different viewers, see Table 1, we noticed that most viewers for ST are either limited to SST techniques [5, 39,59], are not suitable for displaying millions of molecular markers [3,9,32,36,39,47,53], or are too general, not hostable online, and require extensive customization [25].
As the adoption for ST continues to grow, and now with newly emerged end-to-end systems for IST (such as Vizgen's MERSCOPE and 10x Genomic's Xenium), we believe that robust open-source interactive viewers for ST data are essential for researchers studying large-scale spatial omics.
In this paper, we present a web-based viewer that can handle tens of millions of unique markers, and multiple samples, without lag and at interactive frame rates, and without relying on data sub-sampling. Our contributions include maximizing the utilization of web browser capabilities, by leveraging WebGL for efficient GPU-based rendering of markers, and by optimizing how marker location and attributes are stored in memory. In addition to markers, TissUUmaps 3 can also display pie charts, graphs, and regions. Furthermore, we have structured TissUUmaps 3 to be compatible with a wide range of raw and processed data formats used in the community and built a plugin engine to provide a range of interactive analysis tools.

Methods
The improved TissUUmaps 3 implementation includes structural as well as functional changes, with the primary aim of making interactive viewing of large datasets fast and flexible. Here we describe the different implementation improvements in more detail.

Web based interface
The core of TissUUmaps 3 is a web-based interface developed in pure JavaScript and HTML. The JavaScript part depends on multiple open source libraries and technologies: WebGL to display markers with GPU acceleration, OpenSeadragon to display pyramidal images in Deep-Zoom format, PapaParse [24] to load and parse CSV files, h5wasm [40] to load and parse HDF5 files, D3 [16] to display regions, jquery-chosen [1] and jquery-autocomplete [2] for user-friendly inputs. The source code for TissUUmaps-core is available on the TissUUmapsCore GitHub repository at https://github.com/TissUUmaps/TissUUmapsCore Compared to TissUUmaps 1, the main changes on the core web interface are: Improved loading of CSV files: Browsers including Google Chrome and. Mozilla Firefox typically limit the allocation and usage of heap memory to 4 GB per browser tab [21]. In TissUUmaps 1, the whole Table 1 Summary of different tools for visual exploration of ST data. We noticed three approaches for loading image data: Pyramidal loading, where the same image is loaded using different resolutions depending on the zoom-level; HDF5 loading, where HDF5 file format is used for quick retrieval of largescale data; Full loading, where the entire image is loaded into memory. The tools are designed for different types of input data: Regions, such as polygons used for delineating segmented-cells. Single cell features, such as mRNA compositions within cells, that are displayed in a lower-dimensional 2D space, and can be interactively explored; Imaging-based spatial transcriptomics (IST) data, where markers for individual transcripts/molecules are displayed in high quantities and can be interactively explored; Sequencing-based spatial transcriptomics (SST) data, where transcripts are first captured in situ and sequenced ex situ, resulting in high-dimensional data. Some tools are developed using web-based frameworks and are hostable as web-pages, allowing easy sharing of interactive visualizations as online resources. Most tools come with an open source license.

Intended input data
Image data Regions Single cell features IST SST Hostable License CSV file was loaded as a text string into memory and each row was parsed as an object, which could quickly exceed the browser memory limit for datasets with millions of points and many columns. To allow parsing of large CSV files, TissUUmaps 3 uses the JavaScript library PapaParse to stream and process data in chunks. Processed data is stored in a struct-of-arrays (SoA) layout, which allows columns with numeric data to be converted into typed arrays for lower memory consumption compared to the array-of-structs (AoS) layout used in TissUUmaps 1. Columns detected as containing only numeric values are converted and stored in Float64Array format during streaming and after loading. Using an SoA layout for marker data also has the added benefit of making TissUUmaps 3 more suitable for selectively loading columns from HDF5 files (see next item). Loading HDF5 and anndata files: The anndata [61] (annotated data) file format enables flexible storing and bookkeeping of high-dimensional annotated data. As such, it has been adopted by a range of tools in the single cell and spatial omics community, reviewed in Ref. [29]. Using the h5py library on the Python side, and the h5wasm library on the JavaScript side, TissUUmaps 3 can now load anndata files, making it possible to directly and interactively explore statistical results produced by tools such as Squidpy [41] and Scanpy [65]. The anndata format is based on the Hierarchical Data Format (HDF5), enabling efficient selective loading of data columns from the HDF5 file. TissUUmaps 3 can also load HDF5 files that are not formatted as anndata files. Columns with numeric values are read directly as typed arrays which might have lower precision than 64 bits, reducing memory usage. Also, supporting HDF5 in TissUUmaps 3 gives the possibility to selectively load columns and work with very large datasets that would otherwise not fit in memory if the whole file was loaded.
Loading regions with GeoJSON: The file format for reading regions has been changed from a previously used in-house format [54] to the more general and widely adopted format GeoJSON [13]. Regions are displayed as polygons in a Scalable Vector Graphics (SVG) canvas.
WebGL rendering: TissUUmaps 1 [54] used the SVG canvas to display both regions and markers. To reduce the computational cost of rendering the markers as vector graphics, the markers were inserted into a quad-tree data structure and sub-sampled to provide a global overview of the spatial distribution. However, as mentioned above, sub-sampling may result in hiding important information from rare markers. We have therefore rewritten TissUUmaps 3 to make use of GPU acceleration through WebGL, which allows for more efficient use of the computer resources. All markers can now be concurrently and quickly displayed, which gives the user a more accurate idea of the spatial distribution.
Two methods for marker rendering are implemented in TissUUmaps 3: The first method (point sprites) uses the native POINTS primitive of WebGL, which allows efficient rendering because only one vertex per marker needs to be processed by the GPU during drawing. However, WebGL restricts the maximum point sprite size to 256 × 256 pixels, which can be a limitation and issue when displaying large markers such as pie-charts or when viewing TissUUmaps on a high-resolution screen. The second method (instancing) uses the instancing feature of WebGL 2.0 to draw two triangles per marker; this allows arbitrarily large markers to be displayed, but at the cost of an increased number of vertices the GPU needs to process during drawing.
The vertex format used for rendering markers with WebGL requires 32 bytes of memory per marker on the GPU; this includes X and Y coordinates and marker index for selection, as well as other attributes (color, opacity, group ID, etc.) depending on the visualization Fig. 1. Comparison of a. TissUUmaps 1 infrastructure and b. TissUUmaps 3 infrastructure. While TissUUmaps 1 was a static web interface, Tis-sUUmaps 3 is embedded in a Python module useable as a native desktop application, in a docker container, or interactively from a Jupyter Notebook. With its VIPS and OpenSlide image converters, TissUUmaps 3 removes the need for pre-processing images. parameters set by the user. In the special case of pie-chart visualization, marker data will be duplicated to display each individual piechart sector, which will increase GPU memory usage. To avoid having to allocate large temporary buffers in browser memory when transferring processed marker data to GPU memory, uploading to vertex buffers is performed in chunks, using the bufferSubData function in WebGL. A chunk size of 100000 markers is used in the current version of TissUUmaps 3.
Finally, alpha blending is used for anti-aliasing and displaying markers with opacity. Network diagram visualization: In addition to markers, TissUUmaps 3 can be used to display network diagrams (also called graphs), by adding links (edges) between markers (nodes). As for markers, the drawing of edges is implemented in WebGL and therefore benefits from GPU acceleration. Each edge is rendered by instancing two triangles, which allows for antialiasing and setting the thickness of lines. TissUUmaps 3 can thus display millions of anti-aliased edges between markers.

Python web server
While TissUUmaps 1 was only a static web interface, requiring a large amount of pre-processing and installation steps on the user side, TissUUmaps 3 is now embedded dynamically in a Python module to allow simplicity in installation and flexibility of use. The infrastructure of the two softwares is compared in Fig. 1. The source code for the Python TissUUmaps module can be found on the main TissUUmaps GitHub repository: https://github.com/TissUUmaps/TissUUmaps and can be installed with the standard Python package installer pip. The TissUUmaps 3 web interface is served by a Flask server containing a dynamic OpenSlide-based Deep Zoom image converter. This allows the loading of all images recognized by the OpenSlide library (.tiff, .svs, .ndpi, etc.) without the need for preprocessing. For non-pyramidal images, an automatic converter based on VIPS [33] was added to expand the number of image formats supported by TissUUmaps (BigTIFF, OME-TIFF, etc.)

Native desktop application
On top of the flask server, we developed a native desktop application that can be installed and run in all major operating systems (Windows, macOS, Linux). This is implemented as a Qt web engine embedding the web interface, with the flask server running in parallel. The application code is based on PyQt6 and PyQtWebEngine, and makes it easy to use TissUUmaps 3 without access to a web server.

Jupyter Notebook
Jupyter notebooks are a widespread tool for prototyping algorithms, displaying data, and sharing reproducible workflows [11]. The de facto displaying method in notebooks is using libraries such as matplotlib [25]. We developed a Python Application Programming Interface (API) that allows interactive integration of the TissUUmaps 3 web-viewer into notebooks for quickly displaying images, regions, and markers.

Docker container
A docker image is also available to deploy the flask server containing TissUUmaps 3 on container orchestration systems such as Kubernetes, making it possible to share TissUUmaps projects on the web from multiple users.

Plugin engine
TissUUmaps 3 can be extended using plugins. Writing plugins involves programming a backend (the computational part) in Python and a front end (e.g. the web interface) in JavaScript. An API is available on the client side to create input forms for the plugins in a simple way. This allows users to customize TissUUmaps 3 and create their own tools for analysis and exploration. Examples of plugins for specific applications are showcased in Section 3.3.

Results
Here we summarize the new features of TissUUmaps 3, present results from evaluating its performance, and describe new plugins, extensions, and their applications.

Ways of running TissUUmaps
TissUUmaps 3 can be easily installed as a native desktop application using the standard Python package manager pip or a regular Windows installer. It can also be deployed on a large scale using the docker image. Finally, it can be used interactively via a Python API on Jupyter Notebooks. Markers: TissUUmaps 3 can load data from CSV files or anndata/HDF5 files, describing, e.g., IST or SST data, making it simple to load output from software such as StarFish [45], Squidpy [41] and Giotto [17].
Regions: TissUUmaps 3 can load regions in GeoJSON format. As such, TissUUmaps 3 can directly import regions exported from other software supporting GeoJSON, for example, QuPath [9].

Fig. 2.
TissUUmaps is a viewer for large-scale spatial omics data. a Data, in the form of regions and markers, extracted by image analysis or created by a range of different spatial statistics tools can be visualized on top of gigapixelsized image stacks. b Accelerated GPU-based rendering makes image and data interaction fast, via a web or desktop viewer, or as part of a Jupyter Notebook. Interactive object selection, or 'gating', in the feature space is directly displayed in the image space. c Data can be presented and explored as markers in space or summarized in localized pie charts. Plugins for quality control enable visual assessment of raw data associated with decoded IST signals. Non-spatial data can also be interactively explored and selected, or 'gated' signals can be overlaid on top of the original tissue sample. d The data owner can export custom project files or static web pages to be run locally or over the Internet, and external users11 can interactively explore, manually select, and download data from regions of interest.

New marker visualization options
TissUUmaps 3 can display network diagrams using lists of neighbors per marker as edges or from anndata objects containing spatial neighbor graphs pre-computed in Squidpy [41]. Output from cell typing methods such as pciSeq [49] can be presented as pie-charts within TissUUmaps, concisely displaying local cell-type probabilities, as shown in Fig. 2 c.

User interface refinements
Intending to make the software more accessible and easier to use, we have made several refinements concerning TissUUmap's user interface: Image-layers can now be displayed using a composite or collection mode. In composite mode, several layers are merged using different colors into composite, multi-colored images. In collection mode, image layers are displayed side-by-side, as shown in Fig. 3.
Multiple datasets (of markers) can simultaneously be loaded into TissUUmaps 3. These datasets are arranged using different tabs, as shown in Fig. 3.
A configured visualization in TissUUmaps 3 can be saved as a.tmap project for later use or to share on the web. TissUUmaps 3 comes with a capture viewport functionality, allowing the user to capture and save high-resolution screenshots of the current viewport. Fig. 3. Some of the many user interface refinements done to TissUUmaps 3: Images can be displayed either in composite mode or in collection mode. In composite mode, images are blended into a composite multi-colored image. In collection mode, images are displayed side-by-side. The user can interactively adjust image properties, for instance, brightness, contrast, opacity, and color. Multiple datasets (.csv or.h5ad files) can be displayed simultaneously in TissUUmaps 3. The datasets are separated into different tabs. (For interpretation of the references to color in this figure legend, the reader is referred to the Web version of this article.) The user can choose to color markers by a specified column in the loaded.csv or.hdf5 file. The column can either contain categorical labels or numeral values. In the latter case, the markers are colored using a userselected colormap. Additional columns in the loaded file can now specify separate markers' size, opacity, and shape.

Performance improvements & benchmarking
Evolving IST techniques produce huge images with millions of markers, which causes users to need increasingly more powerful computers for data exploration. For this reason, we have intensely focused on improving the performances of TissUUmaps, and here we present the results of evaluating loading time, display time, and memory usage when coping with large amounts of data.

Loading time
First, we explored the loading time of the markers and determined how long it takes from downloading the data to displaying it. The tests were performed on a Vizgen MERFISH FFPE Human Immuno-oncology Dataset [4], and we quantified how fast the data formats used were downloaded, read, and displayed. The entire testing protocol is described in the supplementary material SI 1. Fig. 4 a. shows that loading time is faster and more memory-efficient in TissUUmaps 3. Sub-sampling corresponds to using a random subset of the markers, which is quicker and decreases memory usage but displays incomplete data. HDF5 and CSV are file formats with various overheads, overall speeds, and efficiencies.
We also compared TissUUmaps 3 loading time against Vitessce, a state of-the art API for generating spatial and non-spatial omics data. The testing protocol is described in the supplementary material SI 1. The results shown in Fig. 5 indicate that TissUUmaps 3 performs similarly to Vitessce when using a CSV file format, but when using HDF5 file format, TissUUmaps 3 is significantly faster. Furthermore, our attempts to display over 2 × 10 7 number markers using Vitessce resulted in an unresponsive view, whereas Tis-sUUmaps 3 was able to handle up to 7 × 10 7 markers.

Memory usage
Memory usage was performed on the same Human Immuno-oncology dataset as in the previous section. It measured the total amount of memory used by JavaScript objects as a function of displayed markers. As shown in Fig. 4 b., the memory usage at run-time for both loading and visualizing markers in TissUUmaps 3 is significantly reduced compared to TissUUmaps 1 for the benchmark datasets, allowing larger datasets to be explored. The supplementary material SI 1 describes the complete testing protocol.

Rendering time
We compare TissUUmaps 3 rendering times with its predecessor TissUUmaps 1 by measuring the average drawing time per frame for the datasets and views in Fig. 6. The included datasets were three versions of the Human Immuno Oncology dataset (with 65k, 1.0 M, and 16.7 M points), a Breast cancer ISS dataset [27] with 28k points (available in the TissUUmaps GitHub repository) and the Developmental Human Heart dataset [8] with 2.4 M points. In addition, the quad-tree-based sub-sampling of TissUUmaps 1 was disabled in the code so that time was measured for displaying all data points. The results in Fig. 6 show that the marker rendering time of TissUUmaps 3 is now much faster thanks to the GPU acceleration. This means more markers can be displayed at interactive frame rates without resorting to techniques such as sub-sampling.
It should be noted that some browsers, including Google Chrome and Mozilla Firefox, implement WebGL on top of the software layer ANGLE, which does not support native point sprites in some cases (on Windows with the default DirectX backend) and instead emulate this feature by drawing two triangles per point [20]. We measured frame times for both rendering methods (point sprites and instancing) of TissUUmaps 3 in Google Chrome on Linux, where native point sprites are supported. To see how rendering time also scales with increased GPU performance, measurements were further repeated on a low-end integrated GPU (Intel HD530) and a  Additional details about how frame times were measured for both TissUUmaps 3 and TissUUmaps 1 can be found in the supplementary material SI 1.

Plugins, extensions, and their applications
As mentioned in Section 2.6, TissUUmaps 3 can now be extended with plugins that typically consist of a backend computational part written in Python and a front-end built on the TissUUmaps 3 web interface in JavaScript. Therefore, we provide a plugin template, including an API and several examples of plugins, all collected at https://tissuumaps.github.io/TissUUmaps/plugins/ This allows users to package their code and customize an accompanying parameter selection interface, view-port, and interface for user interaction, as illustrated in Fig. 7 a. Examples of provided plugins are described below. Fig. 7. TissUUmaps 3 plugins; Users may create their own plugins using a template (a). A range of plugins for specific tasks are provided at https:// tissuumaps.github.io/TissUUmaps/plugins/(b-h).

Plugin for an interactive view of point distributions
The Plot Histogram plugin provides a quick overview of ST data distribution, in the form of a histogram, within a manually drawn region of interest. This makes it easy to visually explore similarities and differences within different parts of a tissue section, selecting a region in the viewport, as shown in Fig. 7 b, left, and the corresponding histogram of counts per gene will show up to the right.

Plugin for 2D feature space exploration
A spatial omics data point is typically associated with two different attributes: a spatial position and a feature descriptor. The type of feature descriptor varies between different techniques. For example, in an IST experiment, the descriptor is usually a type of compositional vector, describing the composition of mRNA molecules in a small neighborhood, whereas in a multiplexed immunohistochemistry experiment, the descriptor may be a vector describing the fluorescent signal in different image channels, within e.g. a single cell. Downstream analysis of such descriptors usually leads to the identification of various entities in the tissue, for example, the identification of different cell types. To construct and validate biological hypotheses, it is important to explore data both in terms of physical location and feature similarity. Therefore, we have developed a plugin called FeatureSpace.
The plugin starts with the user computing a 2D projection of the feature descriptor using standard dimensionality reduction techniques such as UMAP [10] or t-SNE [60]. FeatureSpace allows the user to simultaneously display the physical coordinates of each data point on top of image data together with the 2D projection of the feature descriptors. The user can then interactively select regions of interest in either physical space or in feature space, see Fig. 7 c. The plugin will automatically highlight where the selected data points are located in both of the spaces, enabling efficient exploratory analysis of spatial omics data.

Plugin for 3D feature space visualization
A 2D view of a multi-dimensional feature space is often limiting, hiding subclusters. Therefore, we have developed a plugin called FeatureSpace3D, which makes it possible to view and rotate a 3D representation of a feature space. Fig. 7 d illustrates a 3D feature space color-coded according to RGB color space, together with a 2D representation of the corresponding spatial coordinates on top of a tissue section, as described in Ref. [15].

Classification Visualization and Quality Control
Classification is a fundamental step when working with spatial omics data for, e.g., understanding the distribution of cell types in a tissue. Classification techniques and/or parameter settings may result in varying classification results. We created the Classification Visualization and Quality Control, or ClassV&QC plugin to visualize and set side-by-side results of two techniques for classification, as described in more detail in Ref. [12]. Briefly, when comparing the output of two classification techniques, one output is displayed as large circles on the spatial viewport, while the output of the second technique is displayed as small stars on top of the circles. This allows the user to see both classification results at the same time. If the two methods have the same marker coordinates in the.csv files, the plugin can display an interactive confusion matrix where the user can click on the elements of the matrix, and only markers counted in that matrix element are displayed on the Spatial viewport. With this, the user can inspect the classification or the misclassification of two approaches from the spatial point of view. Additionally, the built-in Signal Inspector plugin makes it possible to investigate the result in relation to cut-outs of the local staining patterns, to better evaluate which classification technique is more correct, as shown in Fig. 7 e.

Interaction Visualization and Quality Control
The spatial proximity of two different categories of markers can be quantified by a neighborhood enrichment test. This test assigns higher positive values to a pair of marker categories that are spatially closer to each other than they would be by random, values around zero to a pair of marker categories that are randomly distributed in relation to one another, and lower negative values to a pair of marker categories that are spatially further away from each other than they would be by random. The results of the neighborhood enrichment test can be exported as a matrix where columns and rows represent different marker categories, as described in more detail in Ref. [12]. We created an Interaction Visualization and Quality Control, or InteractionV&QC plugin, which can load a neighborhood enrichment matrix and make it interactive, so the user can click on the elements of the matrix and only those two corresponding marker categories are displayed on the Spatial viewport. Through this, the user can investigate quantified proximity from the spatial point of view, as illustrated in Fig. 7 f.

Plugin for interactive quality assessment for multiplexed image data
Assessing the quality of fluorescent multiplexed image data is a tedious task as it requires the inspection of signals from multiple image layers (such as different fluorescent channels collected from various staining rounds). Therefore, we have developed a plugin named Signal Inspector that allows the user to interactively click anywhere on an image being shown in TissUUmaps 3. The plugin will automatically open a subfigure displaying image content from all remaining image layers. We believe this plugin to be particularly useful for inspecting and assessing the quality of the combinatorial labeling schemes used in IST techniques. As such, the plugin can also display results from decoding methods as traces connecting fluorescent signals across various image layers, see Fig. 7 h.

Plugin for unsupervised data clustering
A single IST experiment can target hundreds of different types of mRNA species (genes) and generate several million molecular markers. Molecular patterns, among this large quantity of markers, become overwhelming if all markers are displayed at oncethere is simply too much information at hand to visually interpret the data. A common strategy to dissect the data is to reduce the number of dimensions, for instance, via clustering. We have therefore developed a plugin to TissUUmaps 3, named Points2Regions, that allows the user to interactively cluster the molecular markers into distinct regions with similar molecular compositions [7], as shown in Fig. 7 g. Since clustering and visualization have been optimized for speed, the resulting visualization of clusters in response to parameter settings takes a few seconds for reasonably sized datasets, making parameter exploration easy.

Interfacing with other software
There are many powerful tools for the analysis of microscopy data, producing regions and markers as output. We provide examples for some widely used open source tools and show how they can interface with visual exploration via TissUUmaps 3: QuPath [9] is an open-source tool for digital pathology, supporting the classification, annotation, and segmentation of different cells and tissue regions. Such results can be visualized as markers or regions in TissUUmaps by exporting the QuPath results to a GeoJSON file which in turn can be read directly into TissUUmaps.
Napari [53] is a python-based multi-dimensional viewer, with a large number of associated packages, e.g., for spatial statistics via Squidpy [41], and cell segmentation via Cellpose [58]. Output from Napari projects, including images, annotations, or labeling (as masks and vector graphics), as well as point clouds, can be loaded in TissUUmaps 3 via a Napari-TissUUmaps 3 plugin available on the Napari Hub, as described in https://tissuumaps.github.io/tutorials/#napari CellProfiler [14,35] is a popular tool for performing high-throughput analyses of microscopy image data. CellProfiler usually outputs results in the form of CSV files, containing locations, and associated feature measurements, that can be loaded as markers directly in TissUUmaps 3, and viewed by selecting columns representing coordinates and features of interest (including marker type and color) in the TissUUmaps 3 GUI.
Fiji [52], another popular tool for image analysis, bundles a lot of plugins that facilitate scientific image processing, including image registration. An example of how the registration functionality of Fiji can be output to fit TissUUmaps 3 is described at https:// github.com/TissUUmaps/TissUUmaps/blob/master/examples/fiji_alignment_dot_extraction.py.

Discussion and conclusion
Spatial transcriptomics was featured as the method of the year in Nature 2020 [34], and a range of ST techniques are now made broadly available by commercial companies. At the same time, the development of new and improved techniques results in output data quickly growing richer in terms of the number of transcripts per unit area, the number of different transcripts detected in parallel, and the dimensions of analyzed tissue samples, calling for tools that can help us comprehend these enormous datasets. A first step is often visualization, and here we believe the efficient rendering and interactive data exploration provided by TissUUmaps 3 is crucial. As the adoption of ST methods continues to grow there may be several areas where TissUUmaps 3 could be expanded with new functionality. Combined analysis of ST data and tissue morphology, building on developments in AI techniques for digital pathology, stands out as a potential area of improvement. The large file sizes associated with tissue specimens pose a challenge for image analysis, as system memory typically is not sufficient to load the entire image at once. This means that tools producing measurements to be used as input for TissUUmaps 3 may pose a bottleneck that could be avoided by adopting packages such as Dask [50], as a means of handling such images by loading subsections of an image on-demand.
We are also following the development of the Open Microscopy Environment -Next-Generation File Formats (OME-NGFF) for cloud-based data storage [37], and we are considering expanding TissUUmaps 3 to directly load such data, in line with the OME-NGFF idea that global, collaborative discovery as opposed to the post-publication, "data-on-request" mode of operation is the path forward. This includes considering cloud storage systems such as Google Cloud Storage (GCS) and Amazon Simple Storage Service (Amazon S3).
So far, we have primarily focused on optimizing TissUUmaps 3 as a data viewer. However, with our recent development of the Points2Regions plugin [7], it has become clear that interactive tools that also include a speed optimized computational step are very valuable for data exploration. With Points2Regions, the user can vary parameters such as the radius of the local neighborhood, and directly explore ST composition ranging from single cells to larger functional tissue regions. We foresee that the integration of Tis-sUUmaps 3 with Jupyter Notebooks may be a good environment for developing more such tools that could eventually be integrated as plugins.
Current tools for interactive region drawing and annotation in TissUUmaps 3 have limited functionality, and users are recommended to annotate tissues using e.g. QuPath (assuming the user has access to the image files locally). Annotations may thereafter be imported as regions to TissUUmaps 3. With the growing interest in spatial omics, new image formats containing marker and region information are being developed, and we see better annotation tools as well as direct loading of these novel image formats as future developments for TissUUmaps 3. In the future, we would like to integrate cloud-based loading into TissUUmaps, i.e., loading data from a URL, and incoporate new cloud-based image formats, such as NGFF [38].
Many different questions can be posed to the same dataset, and data sharing according to the FAIR principles [64], aiming to improve the Find ability, Accessibility, Interoperability, and Reuse of digital assets, is highly relevant for ST data. Visualizing data prior to download is important for judging the relevance of a dataset, and future development for TissUUmaps 3 is a simplified targeted download of, e.g., regions and markers of interest, reducing the time and cost of data sharing. We are already using TissUUmaps 3 as a means of sharing published datasets, as exemplified in our gallery at https://tissuumaps.github.io/gallery/ providing IST and SST data from the Developmental Human Cell Atlas lung [55] and heart [8,44].
In this manuscript, we presented an updated version of TissUUmaps that has been optimized to ensure that it can provide suitable usage performance even as ST datasets are growing exponentially, accommodating the continuous development of ST techniques. We demonstrated that TissUUmaps 3 provides significantly improved performance for large multiplex datasets as compared to previous versions, at the same time as we have increased ease of use and options for customization. We envision TissUUmaps 3 to be a valuable resource for researchers studying large-scale spatial omics data, and we believe that it will contribute to the broader dissemination and flexible sharing of this type of data.