원시데이터 수집 시스템
선정목록으로

MorphoFeatures for unsupervised exploration of cell types, tissues, and organs in volume electron microscopy

관련 수소연료전지 · (7) MEA(막전극접합체)

기본 정보

저자
  1. Valentyna Zinchenko — Cell Biology and Biophysics Unit, European Molecular Biology Laboratory (EMBL)
  2. Johannes Hugger — European Bioinformatics Institute, European Molecular Biology Laboratory (EMBL)
  3. Virginie Uhlmann — European Bioinformatics Institute, European Molecular Biology Laboratory (EMBL)
  4. Detlev Arendt — Developmental Biology Unit, European Molecular Biology Laboratory (EMBL)
  5. Anna Kreshuk — Cell Biology and Biophysics Unit, European Molecular Biology Laboratory (EMBL)
DOI
10.7554/elife.80918
저널
eLife
발행년도
2023
발행기관
eLife Sciences Publications Ltd
피인용수
25
라이선스
cc-by
논문 유형
–
언어
–
원문 페이지
https://doi.org/10.7554/elife.80918
토픽
Electron and X-Ray Spectroscopy Techniques
OpenAlex ID
W4321002241

평가 내용

관련도
관련
사업분야
수소연료전지 · (7) MEA(막전극접합체)
부 분야
–
R&D 측면
–
확신도
–
근거 용어
–
판단 근거
임베딩 유사도 기반 평가로 '수소연료전지 > MEA(막전극접합체)' 분야에 선정된 논문입니다.
R&D 활용 포인트
–
평가 입력
–

초록

Electron microscopy (EM) provides a uniquely detailed view of cellular morphology, including organelles and fine subcellular ultrastructure. While the acquisition and (semi-)automatic segmentation of multicellular EM volumes are now becoming routine, large-scale analysis remains severely limited by the lack of generally applicable pipelines for automatic extraction of comprehensive morphological descriptors. Here, we present a novel unsupervised method for learning cellular morphology features directly from 3D EM data: a neural network delivers a representation of cells by shape and ultrastructure. Applied to the full volume of an entire three-segmented worm of the annelid <i>Platynereis dumerilii</i>, it yields a visually consistent grouping of cells supported by specific gene expression profiles. Integration of features across spatial neighbours can retrieve tissues and organs, revealing, for example, a detailed organisation of the animal foregut. We envision that the unbiased nature of the proposed morphological descriptors will enable rapid exploration of very different biological questions in large EM volumes, greatly increasing the impact of these invaluable, but costly resources.

본문 99,379자

본문 펼치기
*For correspondence: anna.kreshuk@embl.de (A.K.); arendt@embl.de (D.A.) †These authors contributed equally to this work 1 # MorphoFeatures: unsupervised 2 # exploration of cell types, tissues and 3 # organs in volume electron 4 # microscopy 5 Valentyna Zinchenko <sup>1,4†</sup> , Johannes Hugger <sup>2†</sup> , Virginie Uhlmann <sup>2</sup> , Detlev Arendt <sup>3*</sup> , 6 Anna Kreshuk <sup>1*</sup> 7 1Cell Biology and Biophysics Unit, European Molecular Biology Laboratory (EMBL), 8 Heidelberg, Germany; <sup>2</sup> European Bioinformatics Institute, European Molecular Biology 9 Laboratory (EMBL), Cambridge, United Kingdom; <sup>3</sup> Developmental Biology Unit, 10 European Molecular Biology Laboratory (EMBL), Heidelberg, Germany; <sup>4</sup> Collaboration 11 for joint PhD degree between EMBL and Heidelberg University, Faculty of Biosciences 12 13 Abstract Electron microscopy (EM) provides a uniquely detailed view of cellular morphology, 14 including organelles and fine subcellular ultrastructure. While the acquisition and 15 (semi-)automatic segmentation of multicellular EM volumes is now becoming routine, large-scale 16 analysis remains severely limited by the lack of generally applicable pipelines for automatic 17 extraction of comprehensive morphological descriptors. Here, we present a novel unsupervised 18 method for learning cellular morphology features directly from 3D EM data: a convolutional 19 neural network delivers a representation of cells by shape and ultrastructure. Applied to the full 20 volume of an entire three-segmented worm of the annelid _Platynereis dumerilii_, it yields a visually 21 consistent grouping of cells supported by specific gene expression profiles. Integration of 22 features across spatial neighbours can retrieve tissues and organs, revealing, for example, a 23 detailed organization of the animal foregut. We envision that the unbiased nature of the 24 proposed morphological descriptors will enable rapid exploration of very different biological 25 questions in large EM volumes, greatly increasing the impact of these invaluable, but costly 26 resources. 27 28 Introduction 29 Development of multicellular organisms progressively gives rise to a variety of cell types, with dif30 ferential gene expression resulting in different cellular structures that enable diverse cellular func31 tions. Structures and functions together represent the phenotype of an organism. The character32 ization of cell types is important to understand how organisms are built and function in general 33 ( _Arendt_ ( _2008_ )). Recent advances in single-cell sequencing have allowed the monitoring of differ34 ential gene expression in the cell types that make up the tissues and organs of entire multicellu35 lar organisms, and led to the recognition of distinct regulatory programs driving the expression 36 of unique sets of cell type-specific effector genes ( _Hobert_ _and_ _Kratsios_ ( _2019_ ); _Sebé-Pedrós_ _et_ _al._ 37 ( _2018b_,a); _Musser_ _et_ _al._ ( _2021_ ); _Fincher_ _et_ _al._ ( _2018_ ); _Siebert_ _et_ _al._ ( _2019_ )). These distinct genetic 38 programs make the identity and thus define cell types ( _Arendt et al._ ( _2016_ ); _Tanay and Sebé-Pedrós_ 39 ( _2021_ )). The genetic individuation of cell types then translates into phenotypic differences between 1 f 35 40 cells, and one of the most intriguing questions is to determine this causation for each cell type. Only 41 then will we understand their structural and functional peculiarities and intricacies and learn how 42 evolutionary cell type diversification has sustained organismal morphology and physiology. As a 43 prerequisite towards this aim, we need a comprehensive monitoring and comparison of cellular 44 phenotypes across the entire multicellular body, which can then be linked to the genetically defined 45 cell types. 46 Recent efforts have focused on large-scale high-resolution imaging to capture the morpholog47 ical uniqueness of cell types. For the first time, the rapid progress in volume EM allows this for 48 increasingly large samples, including organs and entire smaller animals, with nanometer resolu49 tion ( _Bae_ _et al._ ( _2021_ ); _Vergara et al._ ( _2021_ ); _Zheng et al._ ( _2018_ ); _Scheffer et al._ ( _2020_ ); _Cook et al._ 50 ( _2019_ ); _Verasztó et al._ ( _2020_ )). Supported by automated cell segmentation pipelines ( _Heinrich et al._ 51 ( _2021_ ); _Macrina et al._ ( _2021_ ); _Pape et al._ ( _2017_ ); _Müller et al._ ( _2021_ )), such datasets allow character52 ization and comparison of cellular morphologies, including membrane-bound and membraneless 53 organelles and inclusions, at an unprecedented level of detail for thousands of cells simultaneously 54 ( _Turner_ _et_ _al._ ( _2022_ ); _Vergara_ _et_ _al._ ( _2021_ )). A notable challenge of such large-scale studies is the 55 analysis of massive amounts of imaging data that can no longer be inspected manually. The lat56 est tools for visual exploration of multi-terabyte 3D data allow for seamless browsing through the 57 regions of interest ( _Pietzsch et al._ ( _2015_ ); _Maitin-Shepard et al._ ( _2021_ )), given such regions are spec58 ified and a researcher has a clear study question in mind. However, if the goal is to characterise 59 and/or compare morphologies of most or all cells in the dataset, one has to be able to automati60 cally assign each cell an unbiased comprehensive morphological description - a feature vector with 61 values representing the morphological properties of the cell in the most parsimonious manner. 62 The need for automation and quantitative evaluation has triggered the design of complex en63 gineered features that capture specific cell characteristics ( _Barad_ _et_ _al._ ( _2022_ )). However, such 64 features often have to be manually chosen and mostly provide only a limited, targeted view of the 65 overall morphology. To alleviate this problem, intricate modelling pipelines for cellular morphology 66 quantification have been developed ( _Ruan et al._ ( _2020_ ); _Driscoll et al._ ( _2019_ ); _Phillip et al._ ( _2021_ )), 67 still these are often data- and task-specific. For unbiased monitoring and comparison of cellular 68 morphologies, broadly applicable automated pipelines are missing. They should in addition be 69 capable of extracting comprehensive representations that are not biased by manual feature selec70 tion, the end task or the type of data used. We expect that developing such techniques will not 71 only speed up the process of scientific discovery in big volume imaging datasets, but also facilitate 72 detecting unusual and underrepresented morphologies. 73 In the last decade artificial neural networks have been shown to exceed manually engineered 74 pipelines in extracting comprehensive descriptors for various types of data, and to be particularly 75 suited for the extraction of visual features ( _Krizhevsky_ _et_ _al._ ( _2012_ ); _Falk_ _et_ _al._ ( _2019_ ); _Simonyan_ 76 _and Zisserman_ ( _2014_ ); _Girshick et al._ ( _2014_ )). Moreover, the rise of so-called self-supervised train77 ing methods has removed the necessity for generating massive amounts of manual annotations 78 previously needed to train a network. Besides the obvious advantage of being less labour-intensive, 79 self-supervised methods do not optimise features for a specific end-task, but instead produce de80 scriptors that have been shown to be useful in a variety of downstream tasks, such as image classi81 fication, segmentation and object detection ( _He et al._ ( _2020_ ); _Van den Oord et al._ ( _2018_ ); _Tian et al._ 82 ( _2020_ )). Such methods have already shown to be successful for phenotyping cells in image-based 83 profiling ( _Lu_ _et_ _al._ ( _2019_ ); _Lafarge_ _et_ _al._ ( _2019_ )) and for describing local morphology of patches 84 or subcompartments within neural cells in 3D electron microscopy of brain volumes ( _Huang et al._ 85 ( _2020_ ); _Schubert et al._ ( _2019_ )). Building on the latest achievements, we aim to expand the feature ex86 traction methods to automated characterisation of cellular morphology at the whole animal level. 87 Here we present the first framework for the fully unsupervised characterization of cellular 88 shapes and ultrastructures in a whole-body dataset for an entire animal. We apply this new tool to 89 the fully segmented serial blockface electron microscopy (SBEM) volume of the 6 days post fertilisa90 tion young worm of the nereid Platynereis dumerilii, comprising 11,402 mostly differentiated cells 2 f 35 91 with distinct morphological properties ( _Vergara_ _et_ _al._ ( _2021_ )). We show that our method yields 92 morphological descriptors - _MorphoFeatures_ - that are in strong agreement with human percep93 tion of morphological similarity and quantitatively outperform manually defined features on cell 94 classification and symmetric partner detection tasks. We further illustrate how our features can 95 facilitate the detection of cell types by morphological means, via similarity-based clustering in the 96 MorphoFeature vector space, sorting the cells into morphologically meaningful groups that show 97 high correlation with genetically defined types such as muscle cells and neurons. Our pipeline also 98 allows for the characterization of rare cell types such as enteric neurons and rhabdomeric photore99 ceptors, and detects distinct cell populations within the developing midgut. Finally, defining feature 100 vectors that also represent the morphology of immediate neighbours, we group cells into tissues, 101 and also obtain larger groupings that represent entire organs. We show that such neighbourhood102 based _MorphoContextFeature_ vector clustering reproduces manually annotated ganglionic nuclei 103 in the annelid brain, and represents a powerful tool to automatically and comprehensively detect 104 the distinct tissues that belong to and make up the foregut of the nereid worm - including highly 105 specialised and intricate structures such as the neurosecretory infracerebral gland ( _Baskin_ ( _1974_ ); 106 _Hofmann_ ( _1976_ ); _Golding_ ( _1970_ )) and the axochord that has been likened to the chordate noto107 chord ( _Lauri et al._ ( _2014_ )). We further show that such morphologically defined tissues and organs 108 correlate with cell type and tissue-specific gene expression. Our work thus sets the stage for linking 109 genetic identity and structure-function of cell types, tissues and organs across an entire animal. 110 The MorphoFeatures for the Platynereis dataset, as well as the code to generate and analyse 111 [them are available at https://github.com/kreshuklab/MorphoFeatures.git.](https://github.com/kreshuklab/MorphoFeatures.git) 112 Results 113 Unsupervised deep learning extracts extensive morphological features 114 Our pipeline has been designed to extract morphological descriptors of cells (MorphoFeatures) 115 from EM data. It requires prior segmentation of all the cells and nuclei of interest. The pipeline 116 utilises segmentation masks to extract single cells/nuclei and represents their morphology as a 117 combination of three essential components: shape, coarse and fine texture (Figure 1A). We train 118 neural networks to represent these components independently, using point clouds as input for 119 shape, low resolution raw data for coarse texture with sufficient context and small, high resolution 120 crops of raw data for fine texture. Separating these components ensures they are all represented 121 in the final features, and facilitates further interpretation. The features are combined to form one 122 feature vector for each cell of the animal. 123 A common way to train a neural network for extracting relevant features is to use some prior 124 information about samples in the dataset as a source of supervision. For example, to extract mor125 phological representations of cells one could use a complementary task of predicting cell lines 126 ( _Yao et al._ ( _2019_ ); _Doan et al._ ( _2020_ ); _Eulenberg et al._ ( _2017_ )), experimental conditions the cells are 127 coming from ( _Caicedo et al._ ( _2018_ )), or classification of proteins fluorescently labelled in the cells 128 ( _Kobayashi et al._ ( _2021_ )). However, such metadata is mostly unavailable for EM volumes, and man129 ual annotation might become infeasible with increasing data size. Moreover, exploratory studies 130 are often aimed at discovering unusual morphology, new cell types or tissues. In this case, defining 131 supervision is not only difficult, but might also bias the exploration towards the “proxy” groups used 132 for supervision. To enable immediate data exploration even for datasets where direct supervision 133 is hard to define and the ground truth cannot easily be obtained, we developed a fully unsuper134 vised training pipeline that is based on two complementary objectives (Figure 1B,C). The first is an 135 autoencoder reconstruction loss, where a network extracts a low-dimensional representation of 136 each cell and then uses this representation to reconstruct back the original cell volume. This loss 137 encourages the network to extract the most comprehensive description. The second objective is 138 a contrastive loss that ensures the feature vectors extracted from two similarly looking cells (posi139 tive samples) are closer to each other than to feature vectors extracted from more dissimilar cells 3 f 35 140 (negative samples). Since we do not know in advance which samples can be considered positive for 141 our dataset, we are using slightly different views of the same cell, generated by applying realistic 142 transformations to cell volumes (see Methods). The combination of these two losses encourages 143 the learned features to retain the maximal amount of information about the cells, while enforcing 144 distances between feature vectors to reflect morphological similarity of cells. 145 The pipeline was trained and applied on the cellular atlas of the marine annelid Platynereis 146 dumerilii ( _Vergara et al._ ( _2021_ )). It comprises a 3D serial block-face electron microscopy volume of 147 the whole animal that has sufficient resolution to distinguish ultrastructural elements (organelles 148 and inclusions, nuclear and cytoplasm texture, etc.) and an automated segmentation of 11,402 149 cells and nuclei (Figure 1A). Additionally, whole-animal gene expression maps are available that 150 cover many differentiation genes and transcription factors. 151 Such a high number of morphologically and genetically diverse cells can make the initial ex152 ploratory analysis difficult. We designed MorphoFeatures to enable unbiased exploration of mor153 phological variability in the animal on both cellular and tissue level; and indeed our training pro154 cedure yields 480 features that extensively describe each cell in terms of its cytoplasm and nu155 cleus shape, coarse and fine texture (80 features for each category). The features can be found 156 [at https://github.com/kreshuklab/MorphoFeatures.git,](https://github.com/kreshuklab/MorphoFeatures.git) the feature table can be directly integrated 157 with the Platynereis atlas of _Vergara et al._ ( _2021_ ) through the MoBIE plugin in Fiji ( _Schindelin et al._ 158 ( _2012_ [)) (https://zenodo.org/record/2602755).](https://zenodo.org/record/2602755) 4 f 35 Unsupervised feature extraction ### A Raw data (3D) Segmentation (3D) Cell (3D, masked) Shape Coarse texture Fine texture patches ### B C Contrastive loss min( - ) max( - ) Feature vector X1 . . . . . . . . . Xn Autoencoder loss Contrastive loss max( - ) min( - ) Analysis 2D projection of all cells (UMAP) Figure 1. Deep learning pipeline for extracting MorphoFeatures. A . Cell segmentation is used to mask the volume of a specific cell (and its nucleus) in the raw data. Neural networks are trained to represent shape, coarse and fine texture from the cell volume (separately for cytoplasm and nuclei). The resulting features are combined in one MorphoFeatures vector that is used for the subsequent analysis. B . Training procedure for the shape features. A contrastive loss is used to decrease the distance between the feature vectors of two augmented views of the same cell, and increase the distance to another augmented cell. C . Training procedure for the texture features. Besides the contrastive loss, an autoencoder loss is used that drives the network to reconstruct the original cell from the feature vector 5 f 35 159 MorphoFeatures allow for accurate morphological class prediction 160 Good morphological features should distinguish visibly separate cell groups present in the data. 161 To estimate the representation quality of our MorphoFeatures we quantified how well they can be 162 used to tell such groups apart. We took the morphological cell class labels available in the dataset, 163 proofread, corrected and expanded them. These labels include 7 general classes of cells: neurons, 164 epithelial cells, midgut cells, muscle cells, secretory cells, dark neurosecretory cells and ciliary band 165 cells (Figure 2A) with ~60 annotated cells per class in the whole volume. It is worth noting that these 166 cell classes were chosen based on visual morphological traits and do not necessarily represent 167 genetically defined cell type families ( _Arendt_ _et_ _al._ ( _2019_ )). For example, while ciliary band cells 168 are a small narrow group of morphologically homogeneous cells that likely constitute one cell type 169 family, secretory cells were defined as cells with abundant organelles/inclusions in their cytoplasm 170 that could indicate secretion, spanning a wider range of morphologies and, potentially, genetically171 defined cell types. 172 We extracted MorphoFeatures by passing all the cells through the neural network trained as 173 described above (Figure 1A) and used them as an input to train a logistic regression classifier to 174 predict the above-mentioned cell classes. This classifier has few parameters and can be trained 175 even on the modest amount of labels we have available. If any subset of the features strongly cor176 relates with a given cell class, the model will show high performance. A classifier with MorphoFea177 tures achieved an accuracy of 96%, showing that the learned features are sufficient to distinguish 178 broad morphological classes. To better understand remaining inaccuracies, we show the errors 179 made by the classifier in Figure 2B and Figure S1. This reveals, as expected, that while morphologi180 cally homogeneous classes can be easily separated, the classifier tends to confuse some secretory 181 cells with other types (midgut and epithelial cells) that are also difficult to discern by eye and might 182 well be mis-annotated. It also confuses the general neuron class with neurosecretory cells that 183 represent a subclass of neurons. 184 To illustrate large-scale performance of the broad cell type classification model, we show its 185 predictions on the whole animal in Figure 2C,D and Figure S1B. These results demonstrate that 186 MorphoFeatures are sufficiently expressive to enable training a generalizable model from a small 187 number of labels. Taking epithelial cells as a showcase: while the model was trained exclusively on 188 the cells of the outer animal surface, it successfully predicted the cells outlining the gut opening 189 and the chaetae cells as epithelial as well. Even more convincingly, the model predicted some cells 190 in the midgut region as neurons, which after careful visual examination were indeed confirmed to 191 be enteric neurons. 192 In _Vergara et al._ ( _2021_ ), morphological classification of cells was performed based on manually 193 defined features, including descriptors of shape (e.g., volume, sphericity, major and minor axes), 194 intensity (e.g., intensity mean, median and standard deviation) and texture (Haralick features) ex195 tracted from the cell, nucleus and chromatin segmentations, with 140 features in total. To compare 196 these explicitly defined features with implicitly learned MorphoFeatures, we passed them through 197 the same evaluation pipeline yielding a classifier which achieves the accuracy of 94%, in comparison 198 to 96% achieved by MorphoFeatures. The classifier mostly made similar mistakes, but performed 199 worse on the classes of muscle and epithelial cells. Both sets of features demonstrate high accu200 racy on the broad morphological type classification task. For a more detailed comparison, we turn 201 to a different task which allows us to implicitly, but quantitatively, evaluate how well the features 202 group similar cells together. We use the metric introduced in _Vergara_ _et_ _al._ ( _2021_ ) that is based 203 on the fact that the animal is bilaterally symmetric, thus almost all the cells on one side of the an204 imal will have a symmetric partner. The metric estimates how close a given cell is to its potential 205 symmetric partner in the morphological feature space in comparison to all the other cells in the 206 animal (see Methods). According to this metric our MorphoFeatures are 38% more precise in lo207 cating a symmetric partner than the ones from _Vergara et al._ ( _2021_ ), showing the widely accepted 208 superiority of neural network extracted features to explicitly defined ones. 6 f 35 Muscle Secretory Ciliary band Midgut cells cells cells cells Secretory cells Ciliary band Midgut Neuron Neurosecr. Muscle cells cells cells cells Neurosecr. Muscle Secretory Ciliary band cells cells cells cells ### A B Epithelial cells Neuron cells Neurosecr. cells Muscle cells Secretory cells Ciliary band cells Midgut cells Epithelial Neuron Neurosecr. cells cells cells cells ### C D 25mkm 25mkm 1.0 0.5 0.0 Figure 2. Morphological class prediction. A. Examples of cells from 7 manually defined morphological classes used for evaluation. B. Confusion matrix of class prediction for the logistic regression model. Rows are the labels, columns are the predictions. C. The predicted probability of the epithelial class in the whole animal. Note, that while a few cells on the animal surface have been used for training of the logistic regression, no labels were given in the gut opening or chaetae which are still correctly recognized as epithelial. D. The predicted probability of neural cells in the whole animal. 209 MorphoFeatures correspond to visually interpretable morphological properties 210 Neural networks are often referred to as "black boxes" to signify that it is not straightforward to 211 trace learned features or decisions to specific input properties. To examine whether it is possible 212 to understand which properties of cells were learned by our network, we looked at the groups of 213 extracted MorphoFeatures (coarse and fine texture and shape features). For a set of features in 214 each group we visualised cells that correspond to the maximum and minimum value of the corre215 sponding feature (Figure 3). Visual inspection showed that many of them can be matched to visually 216 comprehensible properties. For example, one of the cytoplasm coarse texture features (Figure 3, 217 upper left) shows its minimal value in cells with a thin layer of cytoplasm surrounding the nucleus 218 and its maximal value in wide muscle cells with prominent fibres and mitochondria. One of the nu219 clear coarse texture features (Figure 3, upper right) differentiates between big round nuclei with 220 a rough surface and smaller extended ones. For fine texture, a cytoplasm-related feature (Figure 221 3, middle left) has its minimal value found in cells with medium-sized mitochondria and Golgi cis222 ternae and its maximum correlated with small dark stretches of cytoplasm in dark neurosecretory 7 f 35 223 cells. One of the nuclear fine texture features (Figure 3, middle right) is the lowest in cells with dark 224 homogenous nuclei and has its peak in nuclei with a distinct dark nucleolus. For shape features 225 of cellular membranes, we observed that some have one extreme in compact roundish surfaces 226 such as neuron somata and the other extreme in long, straight and thin surfaces such as muscle 227 cells (Figure 3, lower left). Shape features of nuclear membranes have some of their minima and 228 maxima in compact deformed shapes and straight elongated or flat shapes (Figure 3, lower right). ###### Coarse texture features Cytoplasm Nucleus Min Max Min Max Nucleus Cytoplasm ###### Fine texture features Min Max Min Max Nucleus Cytoplasm ###### Shape features Min Max Min Max Figure 3. Visualization of the learned features. For each feature, four cells with a minimal (blue) and four cells with a maximal (red) value of the feature are shown, see text for detailed analysis. 8 f 35 229 MorphoFeatures uncover groups of morphologically similar cells 230 Comprehensive analysis of morphological features should enable the grouping of cells with similar 231 morphology, which may represent cell types. We investigated the grouping induced by MorphoFea232 tures by projecting the features of all the animal cells into 2D space using the dimensionality re233 duction technique UMAP ( _McInnes et al._ ( _2018_ )). To explore the quality of our representations, we 234 took a cell from the animal and visualised its 3 closest neighbours (Figure 4A). This indicates that 235 cells in close proximity in the feature space appear highly visually similar and might represent cell 236 types at the morphological level. For example a group of secretory cells in which the cytoplasm 237 is filled with round electron-transparent vesicles (upper green panel) corresponds to the group of 238 ‘bright droplets’ cells from _Verasztó et al._ ( _2020_ ). Another group of secretory cells have an exten239 sive ER surrounding the nucleus with a prominent nucleolus (lower green panel) and represents 240 parapodial spinning gland cells ( _Verasztó et al._ ( _2020_ )). One can also see clear groups of flat devel241 oping midgut cells (brown panel), short muscles (red panel), ciliary band cells on the outer animal 242 surface (yellow panel) as well as extended flat and short round epithelial cells (orange panels). An243 other interesting observation is that even though the neurite morphology is not taken into account, 244 neurons show remarkable diversity based on soma morphology only (blue panels). Careful exami245 nation of a group of cells, initially labelled as neurons, that are located next to epithelial cells on the 246 UMAP projection (upper right blue panel), revealed that these cells are sensory cells that extend 247 their processes to the epithelial surface. 248 To explore the structure of the MorphoFeatures space, we performed hierarchical clustering of 249 all cells. In the first clustering round we split cells into 15 broad morphological groups (Figure 4B). 250 Cluster content could be revealed through available annotations and visualisation with the Platy251 Browser ( _Vergara et al._ ( _2021_ )) (Figure 4B): Clusters 1-8 represent different groups of neurons; 9-11 252 epithelial cells; 12 and 13 were muscles; 14 midgut cells; while cluster 15 was further subclustered 253 into secretory cells (subcluster 1) and ciliary band (subcluster 2). MorphoFeatures can thus guide 254 the morphological exploration of a whole-animal volume, facilitating the discovery and annotation 255 of morphologically coherent groups of cells (Figure 4B). For example, the foregut epithelial cells 256 are distinct from the epithelial cells of the outer animal surface and chaetae cells (clusters 9, 11 257 and 10, respectively). Separate groups are also formed by different types of neurons, for example, 258 foregut neurons (cluster 4). 9 f 35 A B 15 2 1 1 2 3 8 Not labeled Epithelial cells Neuron cells Neurosecretory cells Muscle cells Secretory cells Ciliary band cells Midgut cells 12 13 14 9 11 10 3 7 5 6 1 2 4 10 f 35 Figure 4. A. Finding visually similar cells using MorphoFeatures. Multidimentional features are visualized in 2D using UMAP. Each point represents a feature vector of a cell from the dataset. The cells for which annotations are available are visualized in respective colors. For a random cell, the cell and its three closest neighbors in the UMAP space are visualized in the EM volume. B. Visualising morphological clusters. Clustering results are visualised on the MorphoFeatures UMAP representation. For some clusters the cells comprising the cluster are shown in the animal volume to visualise the cell type. For example, cluster 6 precisely picks out the dark neurosecretory cells, while cluster 14 corresponds to the midgut cells (see Text for more details). 259 Morphological clusters have distinct gene expression profiles 260 To further describe the morphological clusters we took advantage of the whole-animal cellular 261 gene expression atlas available for Platynereis ( _Vergara_ _et_ _al._ ( _2021_ )), containing more than 200 262 genes mapped onto the EM volume. We looked for genes that are highly expressed in a given 263 cluster, while also being specific for this cluster - having low expression in the other cells of the 264 animal. 265 Many of our clusters show a clear genetic signature (Figure 5A, Figure S2). Among the neurons, 266 cluster 5 shows the most specific gene expression including the Transient receptor potential (Trp) 267 channels _pkd2, trpV4_ and _trpV5_, and the bHLH transcription factor _asci_, which demarcate sensory 268 cells of the palpal, antennal, and cirral ganglia ( _Vergara et al._ ( _2021_ )). Cluster 1 shows specific ex269 pression of the homeodomain transcription factors _lhx6_ and _phox2_ and an _ap2_ family member, 270 while cluster 6 composed of dark neurosecretory cells shows specific expression of two neurose271 cretion markers, atrial natriuretic peptide receptor _anpra_ and prohormone convertase _phc2_, iden272 tifying these as brain parts of the circular and apical nervous system, respectively ( _Vergara_ _et_ _al._ 273 ( _2021_ ); _Arendt_ ( _2021_ )). Cluster 8, another neural cluster, is enriched for the oxidative stress marker 274 _cytoglobin_ ( _globin-like_ ) ( _Song et al._ ( _2020_ )) and the bHLH transcription factor _mitf_ . Subclustering re275 vealed 3 subclusters, one of which represents rhabdomeric photoreceptors of the adult eye (Figure 276 4B, subcluster 8.1) that specifically express _mitf_ and _globin-like_ . An average cell in this subcluster 277 (Figure 5B) shows abundant black inclusions. The second subcluster (8.2) contains pigment cells 278 with black pigment granules. Cells in the third subcluster (8.3) are located in the midgut, with a 279 smooth oval shape, neurite extensions and nuclei taking up the most cell volume (Figure 5C,D) 280 in striking contrast to other midgut cells but resembling neurons, making it likely that these cells 281 represent enteric neurons previously postulated on the basis of serotonin staining ( _Brunet_ _et_ _al._ 282 ( _2016_ )). 283 Among the epidermal cells, the outer cluster 11 is enriched for _protocadherin_ ( _pcdh15_ ) and _neu-_ 284 _rotrypsin_ ( _ntrps_ ), whereas cluster 9 representing foregut epidermis shows high specificity for the 285 bHLH transcription factor _sim1_ and the homeodomain factor _pou3_ ( _brn124_ ) (known to be expressed 286 in stomodeal ectoderm in sea urchin ( _Cole_ _and_ _Arnone_ ( _2009_ )). For the muscles, the specific ex287 pression of striated muscle-specific myosin heavy chain _mhcl4_ in cluster 12 denotes the group of 288 striated somatic muscles, while its absence in cluster 13 indicates that the foregut muscles have 289 not yet switched to expressing striated markers ( _Brunet et al._ ( _2016_ )). Instead, the high and specific 290 expression of the calexcitin-like sarcoplasmic calcium-binding protein _Scp2_ ( _calexcitin2_ ) ( _White et al._ 291 ( _2011_ )), _calmodulin_ and of the Boule homolog _Boll_ ( _boule-like_ ) in cluster 13 suggests a calcium exci292 tation and/or sequestration mechanism specific for foregut muscles. Finally, the cluster of midgut 293 cells (cluster 14) specifically expresses the forkhead domain transcription factor _foxA_ ( _for_ ), a gut 294 developmental marker ( _Boyle_ _and_ _Seaver_ ( _2008_ )) and _TrpV-c_, another Trp channel paralog of the 295 vanilloid subtype with presumed mechanosensory function. 11 f 35 #### A Neurons Epithelial cells Photoreceptors Muscles Midgut cells Cluster Cluster #### B C D 8.1 8.3 0.8 0.6 0.4 0.2 0.0 Figure 5. Clustering and gene analysis. A. Gene expression dot plot. The size of dots shows how much of the cluster expresses a gene; the colour shows how much of the expression of the gene is confined to a cluster (see Methods). The genes mentioned in the text are enboxed. The clusters lacking highly specific gene expression were not included. B-C. The average shape and texture (see Methods) rhabdomeric photoreceptors (cluster 8.1) and (C) the enteric neurons (cluster 8.3). D. Localisation of the enteric neurons (pink) in the midgut volume (grey). Left: frontal view, right: side view. 296 Beyond that, we noted considerable genetic heterogeneity in the midgut cluster. Subclustering 297 (Figure 6) revealed one subcluster with strong expression of the smooth muscle markers _non-_ 298 _muscle-mhc_ and _mrlc2_, and another expressing a chitinase related to chitotriosidase ( _nov2_ ) and 299 the zinc finger transcription factor _Prdm16/mecom_, known to maintain homeostasis in intestinal 300 epithelia ( _Stine et al._ ( _2019_ )). Visualising the cells belonging to each subcluster and the specifically 301 expressed genes in the PlatyBrowser (Figure 6E) revealed distinct territories in the differentiating 302 midgut, which we interpret as midgut smooth musculature and digestive epithelia. We also de303 tected an enigmatic third cluster located outside of the midgut, in the animal parapodia, compris304 ing cells that resemble midgut cells morphologically (Figure 6D). For this subcluster, the current 305 gene repertoire of the cellular expression atlas did not reveal any specifically expressed gene. 12 f 35 # A # B Smooth muscles Digestive cells 0.8 0.6 0.4 0.2 0.0 # C gcb mecom nov2 ppib D gcb mecom nov2 ppib mrlc2 non-muscle-mhc sema2 Digestive cells Digestive cells # E irx6 Smooth muscles Smooth muscles nov2 ppib mrlc2 non-muscle-mhc nov2 ppib mrlc2 non-muscle-mhc 13 f 35 Figure 6. Midgut cell types with defining genes. A. Finer clustering of the midgut cluster results in three subclusters. B. Gene expression dot plot of the two midgut subclusters that are presumably developing smooth muscles and digestive cells of the midgut. The size of dots shows how much of the cluster expresses a gene; the colour shows how much of the expression of the gene is confined to a cluster (see Methods). C. Some of the genes shown to be differentially expressed in the two subclusters, plotted on the UMAP representation. D. The location (upper panel) and an example cell (lower panel) of the subcluster located in the animal parapodia. E. Cells belonging to the two cell types (left panels) and the genes differentiating them (center and right panels) are visualised in the animal volume, with color representing gene expression overlayed on the EM plane view. 306 Adding neighbour morphological information helps to identify tissues and organs 307 Most cells do not function in isolation but rather form tissues, i.e. groups of structurally and func308 tionally similar cells with interspersed extracellular matrix. We set out to systematically identify 309 tissues with a new feature vector assigned to each cell that takes into account information about 310 the morphology of neighbouring cells. For this, we combined the MorphoFeatures of a cell with the 311 average MorphoFeatures of its immediate neighbours, yielding a feature vector that represents the 312 morphology of both the cell and its surrounding, which we refer to as MorphoContextFeatures. 313 Applying the representation analysis described before, we find that proximity in MorphoCon314 textFeature space no longer reflects morphological similarity only, but rather identifies neighbour315 ing groups of morphologically similar cells (whereby the neighbouring groups can be morphologi316 cally dissimilar). In other words, we now identify different tissues that together constitute organs 317 composed of various tissues (Figure 7). For example, a separate assembly of groups of cells in the 318 lower part of the UMAP projection represents the animal foregut subdivided into its constituting 319 tissues comprising foregut neurons (lower left blue panel), foregut muscles (lower red panel) and 320 foregut epithelium (left orange panel). Next to this we identify a group of muscles surrounding the 321 foregut (middle left red panel). 322 For the nervous system, adding neighbourhood information helps distinguishing cirral, palpal and 323 dorsal ganglia (upper blue panels from left to right), as well as the ventral nerve cord and periph324 eral ganglia (lower and middle right blue panels). To benchmark the quality of this grouping, we 325 clustered all the cells in the MorphoContextFeature space (see Methods), and compared the neu326 ron clusters to both manually segmented ganglionic nuclei and to the genetically defined neuronal 327 clusters taking into account available gene expression in the cellular atlas ( _Vergara_ _et_ _al._ ( _2021_ )) 328 (Figure 8A,B). Notably, manual segmentation of brain tissues relied on visible tissue boundaries, 329 thus has lower quality in the areas where such boundaries are not sufficiently distinct. 330 In essence, all three ways of defining ganglia lead to very similar results (Figure 8B), yet MorphoCon331 textFeature clustering appeared to be the most powerful. Gene clustering failed to distinguish the 332 circumpalpal ganglion, defined both by manual segmentation and MorphoContextFeature clus333 tering, due to the lack of distinct gene expression in the atlas. Manual segmentation failed to 334 distinguish between the dorso-posterior and dorsal-anterior ganglionic nuclei due to the lack of 335 distinct tissue boundaries. These are well defined by gene clustering, and subdivided even further 336 by MorphoContextFeature clustering. 14 f 35 Not labeled Epithelial cells Neuron cells Neurosecretory cells Muscle cells Secretory cells Ciliary band cells Midgut cells Figure 7. Characterizing neighbourhoods with MorphoContextFeatures. Panel colors represent classes cells belong to. Upper panels (from left to right): secretory (green) and epithelial (orange) cells of parapodia, antennal muscles that participate in moving and retracting antenna (red), cirral (blue), palpal (blue) and dorsal (blue) ganglia. Lower panels: foregut muscles (red), foregut neurons (blue), infracerebral gland (blue), ventral nerve cord (blue). Left panels: muscles surrounding the foregut (red), foregut epithelium (orange). Right panels: epithelial-sensory circumpalpal cells (orange) and peripheral ganglia (blue). 15 f 35 ##### A B C D Manually segmented regions MorphoContextFeature clusters Gene clusters PG AG CpG MB DG CG VNC nompc3 ptf1 gppcr21 trk grm7 phc2 hox1 nk6 0.8 0.6 0.4 0.2 0.0 16 f 35 Figure 8. MorphoContextFeatures define ganglionic nuclei. AB. The animal ganglia as defined by manual segmentation ( _Vergara et al._ ( _2021_ )), our MorphoContextFeature clustering and gene expression clustering displayed on (A) the UMAP representation and (B) in the animal volume. C. Gene expression dot plot of the ganglia defined by MorphoContextFeature clustering. The size of dots shows how much of the cluster expresses a gene; the colour shows how much of the expression of the gene is confined to a cluster (see Methods). D. Some of the genes shown to be differentially expressed in the ganglia defined by MorphoContextFeature clustering, plotted on the UMAP representation. 337 Unbiased exploration of foregut tissues 338 To further illustrate how MorphoContextFeatures can assist an unbiased exploration of an animal 339 EM volume, we focused on the foregut. Subclustering whenever suitable (Figure 9A) (see Methods), 340 the resulting clusters revealed various foregut tissues including foregut epidermis, ganglia, inner 341 musculature and a prominent muscle surrounding the foregut. We also found a tissue of secretory 342 neuron-like cells that surround the foregut like a collar (Figure 9B,C). 343 Further inspection revealed that the latter structure is located underneath the brain neuropil and 344 close to the neurosecretory endings of the neurosecretory plexus ( _Verasztó_ _et_ _al._ ( _2020_ )) and is 345 bounded by thin layers of longitudinal muscle fibres on both the outer and the inner surface (Fig346 ure S4A). The location of the structure indicated it might represent the differentiating infracerebral 347 gland - a neurosecretory gland located beneath the brain assumed to play a role in sensing blood 348 glucose levels ( _Backfisch_ ( _2013_ ); _Baskin_ ( _1974_ ); _Hofmann_ ( _1976_ ); _Golding_ ( _1970_ )). The organ is leaf349 shaped and lays between the posterior pair of adult eyes (Figure S4B) as also described in ( _Back-_ 350 _fisch_ ( _2013_ )) and borders a cavity likely to be a developing blood vessel (Figure S4C). In comparison 351 to the foregut neurons that express sodium channel _scn8aa_, the infracerebral gland cells specif352 ically express homeobox protein _onecut/hnf6_ (Figure 9D,E). We also noted that the tissue stains 353 positive for EdU applied between 3 and 5 dpf, indicating that it is still proliferating. 354 We then identified the prominent muscles surrounding the foregut as the anterior extension of the 355 axochord ( _Lauri et al._ ( _2014_ )). Visualising the genes specifically expressed in the muscles around 356 the foregut, we noticed specific expression of the type I collagen gene _col1a1_, a marker for axo357 chordal tissue, and of muscle junctional gene _junctophilin1_ (Figure 9F). An anterior extension of the 358 axochord around the foregut has been observed in several species and is described in _Lauri et al._ 359 ( _2014_ ); _Brunet et al._ ( _2016_ ); _Nielsen et al._ ( _2018_ ). 17 f 35 <u>A</u> B C D E boule-like brn124 calexcitin2 grm7 hnf6 co1a1 junctophilin1 sim1 unc22 Foregut muscles Axocord muscles Foregut neurons Infracerebral gland Foregut epithelium 0.8 0.6 0.4 0.2 0.0 F co1a1 junctophilin1 co1a1 junctophilin1 co1a1 junctophilin1 Figure 9. Detailed characterization of the foregut. A. Foregut region clusters plotted on the UMAP representation. B. The foregut tissues, as defined by the MorphoContextFeatures clustering, shown in the animal volume. C. A 3D visualisation of the foregut tissues, as defined by the MorphoContextFeatures clustering: all tissues (upper left panel), surrounding muscles removed (upper right panel), both muscle groups removed (lower panel). D. Some of the genes shown to be differentially expressed in the foregut region clusters, plotted on the UMAP representation. E. Gene expression dot plot of the foregut region clustering. The size of dots shows how much of the cluster expresses a gene; the colour shows how much of the expression of the gene is confined to a cluster (see Methods). The genes mentioned in the text are enboxed. F. The genes specific to the axocord muscles, visualised on the animal volume. 18 f 35 360 Discussion 361 We presented an automated method of extracting comprehensive representations of cellular mor362 phology from segmented whole-animal EM data. In stark contrast to the currently available meth363 ods, ours refrains both from specifying features explicitly and from predefining a concrete task 364 that might skew the method towards extracting specific features: putting emphasis on some fea365 tures may bias descriptions towards specific morphologies or cell types, hindering exploratory 366 analysis. To obtain extensive generally useful representations we rely on the latest progress in 367 self-supervised deep learning and set only two criteria for the extracted features: (1) they have to 368 be sufficiently detailed to allow reconstructing the original cell volume and (2) they have to bring 369 visually similar cells in feature space closer to each other than dissimilar ones. We train a deep 370 learning pipeline optimised for these two conditions and show that it produces rich cellular repre371 sentations, combining shape-, ultrastructure- and texture-based features. More precisely, we show 372 that the obtained representations (MorphoFeatures) capture fine morphological peculiarities and 373 group together cells with similar visual appearance and localization in the animal. Clustering of 374 cells in the MorphoFeature space, and taking advantage of an existing gene expression atlas with 375 cellular resolution, we show that the obtained clusters represent units with differential and coher376 ent gene expression. 377 Both for morphological type and for tissue detection we illustrate how MorphoFeatures can fa378 cilitate unbiased exploratory analysis aimed at detecting and characterising unusual phenotypes 379 or unusual cell neighbourhoods. Moreover, we show quantitative superiority of MorphoFeatures 380 over a broad range of manually defined features on the tasks of cell classification and symmetric 381 partner detection. We also show that, despite being learned implicitly, MorphoFeatures still corre382 spond to visually understandable properties and can often be interpreted. Finally, adding morpho383 logical information from the neighbouring cells (MorphoContextFeatures), we reveal the power of 384 our approach to detect local groups of cells with similar morphology that represent tissues. 385 Since our pipeline is based on the fast-evolving field of self-supervised deep learning, we expect 386 it to further improve with its general advancement. For example, a promising direction are mod387 els, such as _Grill_ _et_ _al._ ( _2020_ ), that only rely on positive samples and remove the need to define 388 which cells belong to a different type. Besides MorphoFeatures, we also believe that MorphoCon389 textFeatures, which incorporate neighbourhood information, will potentially benefit from state-of390 the-art self-supervised techniques such as contrastive learning techniques on graphs ( _Hassani and_ 391 _Khasahmadi_ ( _2020_ ); _Velickovic_ _et_ _al._ ( _2019_ )). Another interesting direction enabled by the modu392 larity of our pipeline is to integrate data from other modalities. Our features currently integrate 393 shape and texture information of cells, but one could also envision enriching cellular descriptions 394 by adding different types of data, e.g. transcriptomics, proteomics or metabolomics, in a similar 395 manner. 396 Versatility of the MorphoFeatures toolbox 397 We envision our pipeline to enable, for the first time, fast systematic investigation of large EM 398 volumes that involves consistent grouping and characterization of morphological types, discover399 ing particular phenotypes and neighbourhoods, as well as localising cells or tissues in an animal 400 volume that are visually similar to cells or groups of cells of interest. Moreover, we expect Mor401 phoFeatures to be useful for studies where several image volumes of the same species are ac402 quired, be it another sample, a varying phenotype, or a different developmental stage. In such 403 cases, one could envisage using morphological representations to map cells to their correspond404 ing partners in another volume, enabling unbiased comparative analysis at scale. In addition, in 405 case the other volumes are not segmented, one could use the fine texture part of MorphoFeatures 406 to locate patches with phenotypic characteristic signature or cells with distinct ultrastructure (e.g., 407 muscles, secretory cells). Using fine texture descriptors in such cases can also facilitate further 408 segmentation, since the segmentation of the previous volume can be used to define constraints of 409 which textures can co-occur in the cells of the animal. However, given the high sensitivity of neural 19 f 35 410 networks to intensity variations, it will be essential to avoid non-biological systematic change in the 411 visual appearance of cells such as intensity shifts, both within and between the EM volumes. 412 The presented pipeline can also be adjusted for other types of data. For example, since our analysis 413 revealed a high variability in neuronal soma morphologies, it appears reasonable to also apply the 414 pipeline to brain EM volumes, where MorphoFeatures could supplement neuron skeleton features 415 for more precise neuronal morphology description. We also expect the approach to contribute to 416 the analysis of cells in other volumetric modalities, such as X-ray holographic nano-tomography 417 ( _Kuan_ _et_ _al._ ( _2020_ )). For light microscopy with membrane staining, we expect the shape part of 418 the MorphoFeatures pipeline to be directly applicable and a useful addition to existing analysis 419 tools. Generally, the versatility of the pipeline is enhanced by its modularity that makes it possi420 ble to adapt different parts (e.g., cell shape or nucleus fine texture) to datasets where not all the 421 morphological components are desired or can be extracted. 422 Identification of cell types and cell type families with MorphoFeatures 423 Any attempt to define cell types morphologically has so far been hampered by the selection of 424 relevant properties. What are the morphological features that are best suited for recognizing cell 425 types? Regarding neurons, the shapes of dendrites and axons, soma size and spine density have 426 been measured, in combination with physiological properties including resting potential, biophys427 ical properties and firing rate ( _Zeng and Sanes_ ( _2017_ )). Volume EM has recently allowed consider428 able expansion of morphometric parameters, including various shape, intensity and texture fea429 tures ( _Vergara_ _et_ _al._ ( _2021_ )). Using these numerous parameters, it is possible to discern general 430 categories such as neurons, muscle or midgut cells; yet they do not provide further resolution 431 within these groups. Comparing the MorphoFeatures representations to the predefined features 432 ( _Vergara et al._ ( _2021_ )) hints at supreme resolution power that appears to distinguish morphologi433 cal groupings down to the cell type level (Figure S3). For example, the subclusters of rhabdomeric 434 photoreceptors of the adult eye and enteric neurons can not be identified in the explicit features 435 representation. Furthermore, the cluster of foregut muscles revealed by the MorphoFeatures ap436 pears to be split, with some cells being found closer to striated muscles, and some residing between 437 the groups of neurons and dark neurosecretory cells. 438 Most important, the cell clusters identified in MorphoFeature space appear to come closest to 439 genetically defined cell types, as demonstrated here, among others, for different types of mechano440 sensory cells, or cell types of the apical nervous system. Interestingly, the MorphoFeatures also 441 unravel morphological cell types without a genetic match in the cell type atlas (such as the enteric 442 neurons, see above). This is most likely due to the yet limited coverage of the atlas and expected 443 to improve with the continuous addition of genes to the atlas. In particular, the integration of 444 other multimodal omics datasets such as single cell transcriptomics data will be highly rewarding 445 to improve the match between morphological and molecularly defined cell types, which is the 446 ultimate aim of cell type characterization and categorization ( _Zeng and Sanes_ ( _2017_ )). 447 Towards an unbiased whole-body identification of tissues and organs 448 The current revolution in the generation of giant volume EM datasets including representations 449 of entire bodies calls for new strategies in the automated processing and comparison of such 450 datasets. This not only involves segmentation and characterization at the cellular level, but also 451 requires the automated identification of discernable structures at the level of tissues and organs. 452 So far, the recognition of tissues in larger volumes was achieved by manual segmentation. We now 453 present a powerful new algorithm to recognize tissues and organs via their co-clustering in the Mor454 phoContextFeature space, which takes into account similarities between neighbouring cells. Using 455 this algorithm, we reproduce and partially outperform tissue recognition via manual segmentation 456 - as exemplified for the ganglionic nuclei of the nereid brain. Beyond that, we present a compre457 hensive account of foregut tissues, without prior manual segmentation. This analysis reveals a rich 458 collection of tissues including an anterior extension of the axochord surrounding the foregut ( _Lauri_ 20 f 35 459 _et al._ ( _2014_ )) and the infracerebral gland ( _Baskin_ ( _1974_ ); _Golding_ ( _1970_ )), an adenohypophysis-like 460 neurosecretory tissue that we identify as anterior bilateral extensions of the foregut roof. 461 While the manual segmentation of tissues mostly relies on the detection of tissue boundaries, our 462 automated tissue detection equally processes the morphological similarities of its constituting cells. 463 This enables tissue separation even in cases where morphological boundaries appear to be absent, 464 as is the case for the anterior and posterior dorsal ganglionic nuclei, which are lacking a clear 465 boundary but are composed of morphologically different cell types that are also genetically distinct 466 ( _Vergara et al._ ( _2021_ )). 467 Conclusion 468 The revolution in multi-omics techniques and volume electron microscopy has unleashed enor469 mous potential in generating multimodal atlases for tissues as well as entire organs and animals. 470 The main unit of reference in these atlases is the cell type, which has been defined, and is manifest, 471 both molecularly and morphologically. Our work now provides a versatile new tool to recognize cell 472 types in an automated, unbiased and comprehensive manner solely based on ultrastructure and 473 shape. For the first time, the MorphoFeatures will allow us to compare and identify correspond474 ing cell types in datasets of the same species, but also between species, on purely morphological 475 grounds. 476 Furthermore, the MorphoContextFeatures automatically recognize tissues and organs across en477 tire bodies, opening up new perspectives in comparative anatomy. Without previous knowledge, 478 we can obtain the full complement of tissues and organs for a given specimen, and quantitatively 479 compare them to those of other specimens of the same or other species. In combination with cell 480 type-, tissue-, and organ-specific expression data this will enable us to identify corresponding traits 481 in an unbiased manner and with unprecedented accuracy. 482 Methods and Materials 483 Data and preprocessing 484 Data 485 We used the dataset of the marine annelid Platynereis dumerilii at late nectochaete stage (6 dpf) 486 from _Vergara_ _et_ _al._ ( _2021_ ). The dataset comprised an SBEM volume of the complete worm in 487 10 × 10× 25 nm resolution, 3D cell and nucleus segmentation masks as well as WMISH gene expres488 sion maps. The segmentation contains 11,402 cells with nuclei that belong to multiple genetically 489 and morphologically distinct cell types. It is important to note that for neurons only somata were 490 segmented, since the imaging resolution did not allow for neurite tracing. The gene expression 491 maps cover mainly differentiation genes and transcription factors, which were registered onto the 492 EM volume, exploiting high stereotypy of the platynereis at this stage of development. Gene ex493 pression values were also assigned to the EM segmented cells. The maps contain 201 genes and 4 494 EdU proliferation stainings. We refer to _Vergara et al._ ( _2021_ ) for further details. Since the intensity 495 correction algorithm that was used in the EM volume performed unreliably in regions close to the 496 boundaries of the volume in the z-axis, we excluded all cells located within the region of uncer497 tain intensity assignment quality. These regions correspond to parts of the animal’s head and the 498 pygidium. 499 Preprocessing 500 The EM dataset is used to extract the three morphological components separately for cytoplasm 501 and nuclei as follows. Due to the limitations of the GPU memory, for the coarse texture a central 502 crop is taken from a downsampled version of the data (80 × 80 × 100 nm). The centre of mass 503 of the nucleus is determined, and a bounding box of size 144 × 144 × 144 pixels (cytoplasm) or 504 104 × 104 × 104 (nuclei) is taken around it. During prediction the bounding box is increased to 505 320 × 320 × 320 (cytoplasm) and 160 × 160 × 160 (nuclei) to fit more information. Fine texture patches 506 have a higher resolution (20 × 20 × 25 nm) and are taken separately from cytoplasm and nucleus. 21 f 35 507 For this the bounding box surrounding cytoplasm or nucleus is split into cubes of 32×32×32 pixels, 508 and only those cubes are considered, which are less than 50% empty. For both coarse and fine 509 texture the data is normalised to the range of [0, 1] and for cytoplasm crops the nuclei are masked 510 out and vice versa. 511 In order to obtain point clouds and normals of the membrane surfaces, we first converted the 512 segmented 3D voxel volumes into triangular meshes. More specifically, we first applied the march513 ing cubes algorithm ( _Lorensen_ _and_ _Cline,_ _1987_ ; _Van_ _der_ _Walt_ _et_ _al.,_ _2014_ ) followed by Laplacian 514 smoothing ( _Schroeder_ _et_ _al.,_ _1998_ ) to obtain smooth triangular surface meshes. These meshes 515 were then simplified and made watertight using _Stutz and Geiger_ ( _2020_ ); _Cignoni et al._ ( _2008_ ). Hav516 ing obtained smooth triangular meshes enables us to compute consistent normals and to apply 517 complex deformations to the underlying surface. During training and inference, the meshes and 518 their surface normals are sampled uniformly to be then processed by the neural network. 519 Unsupervised deep learning pipeline 520 This section describes our proposed algorithm in more detail. On a high level, our model consists 521 of six encoder networks which leverage graph convolutional as well as regular convolutional layers 522 in order to learn shape and texture aspects of a cell’s morphology. We are using self-supervised 523 learning in combination with stochastic gradient descent in order to obtain good network param524 eters. The objective that is optimised is a weighted sum of the NT-Xent loss ( _Chen_ _et_ _al._ ( _2020_ )) 525 and the mean squared error and can be interpreted as an unbiased proxy task. We will detail and 526 elaborate on these aspects in the following sections. 527 Neural network model 528 The proposed network, as depicted in (Figure 1A), contains six encoders which are encoding shape, 529 coarse and fine-grained texture of cells and nuclei. 530 The shape encoder takes as input a set of points in the form of 3D Euclidean coordinates as well 531 as the corresponding normals (see Data and preprocessing) and outputs a N-dimensional shape 532 feature vector. The network itself is a DeepGCN model ( _Li_ _et_ _al._ ( _2019_ )), which is a deep neural 533 network for processing unstructured sets such as point clouds. Conceptually it consists of three 534 building blocks. In the first block, k-nearest neighbour graphs are built dynamically in order to 535 apply graph convolutions. This can be interpreted as pointwise passing and local aggregation of 536 geometric information which is repeated multiple times. In the second block, the pointwise ag537 gregated geometric information is fused by passing it through a convolutional layer followed by a 538 max pooling operation that condenses the information into a high-dimensional latent vector. Fi539 nally, the obtained latent vector is passed through a multilayer perceptron to obtain the shape 540 component of the overall feature vector. 541 The encoding of fine texture details and coarser contextual information is done using the encoder 542 of a U-Net ( _Ronneberger et al._ ( _2015_ )). The fully convolutional network reduces spatial information 543 gradually by employing 3 blocks that consist of 3D convolutional layers with ELU activations ( _Clev-_ 544 _ert_ _et_ _al._ ( _2015_ )) separated by 3DMaxPooling layers. The number of feature maps starts with 64, 545 increases twofold in each block, and afterwards gets reduced to 80 by an additional convolutional 546 layer followed by an ELU activation. In the end a global average pooling operation is applied to 547 reduce feature dimensionality from 3D to 2D. To ensure that empty regions of the data are not 548 affecting the final feature vector, they are excluded for this final pooling. 549 Training 550 In order to find suitable representations we leverage self-supervised contrastive learning (CL) ( _Chen_ 551 _et_ _al.,_ _2020_ ; _Hadsell_ _et_ _al.,_ _2006_ ). The idea is to create a representation space in which morpho552 logically similar cells are embedded close to each other, while dissimilar ones are embedded far 553 apart. For learning representations of shape, we follow a purely contrastive approach, whereas 554 for texture representations we combine the CL objective with an Autoencoder reconstruction loss. 22 f 35 555 Both are described in more detail below. 556 The training procedure for CL is the same for shape and texture representations. First, we ran557 domly sample a mini-batch of cells or nuclei. Two augmented views are then created for each 558 sample in the batch (see Data augmentations) and concatenated to form an augmented batch of 559 twice the size. The augmented batch is passed through the neural network encoder to compute 560 representations. Those representations that share the same underlying sample are considered as 561 positive pairs whereas the others are considered as negative pairs. The NT-Xent loss ( _Chen et al.,_ 562 _2020_ ) is then used to score the representations based on their similarity, and, therefore, encour563 ages the network to embed positive pairs closer to each other than negative pairs. 564 For learning shape representations, we first augmented all cell and nucleus meshes using bihar565 monic deformation fields and as-rigid-as-possible transformations in a preprocessing step (see 566 Data augmentation). More specifically, we computed 10 random views for each membrane sur567 face. The augmented meshes are then used for training, i.e. we compute surface normals and 568 sample 1024 points and their corresponding normals which form the inputs of the shape encoders. 569 In each training iteration, we sampled 48 cells/nuclei, which resulted in a batch size of 96. Adam 570 ( _Kingma_ _and_ _Ba,_ _2014_ ) with a learning rate of 0.0002 and a weight decay of 0.0004 was used to 571 update the network parameters. The hyperparameters were obtained by a random search. 572 In order to learn representations of texture, we combine the NT-Xent loss with an Autoencoder 573 reconstruction objective. The latent representations, taken before the dimensionality reduction 574 step of global average pooling, are further processed by a symmetric decoder part of the UNet 575 network with only 1 block, which aims to reconstruct the network inputs. The reconstructions are 576 then compared to the original inputs and scored by a mean squared error loss. Additionally, an 577 L2-Norm loss was applied to flattened bottleneck features to restrict the range of possible values. 578 The final loss is thus a weighted sum of the NT-Xent, the mean squared error loss and the L2-Norm 579 loss. The batch size was set to 12 and 16 for cell and nuclei coarse texture and to 32 for fine texture. 580 For training we used Adam ( _Kingma and Ba, 2014_ ) as optimizer with a learning rate of 0.0001 and 581 a weight decay of 0.00005. The model was evaluated every 100 iterations and the best result was 582 saved with a patience of 0.95. The learning rate was reduced by 0.98 whenever the validation score 583 did not show improvement with a patience of 0.95. 584 Data augmentation 585 A key component for successful contrastive representation learning are suitable data augmenta586 tions. In our context, applying augmentations to a cell can be interpreted as creating morpholog587 ical variations of a cell. By creating positive and negative pairs (cf. previous section), the network 588 learns to distinguish true variations from noise and non-essential ones. It is therefore important 589 to find a suitable set of transformations that distort the right features of a cell and do not change 590 its morphological identity. 591 As augmentations for shape we leveraged biharmonic and as-rigid-as-possible transformations 592 ( _Botsch_ _and_ _Kobbelt,_ _2004_ ; _Sorkine_ _and_ _Alexa,_ _2007_ ) as they deform cellular and nuclear mem593 branes in a way that retains most characteristic geometric features of the original surface. In or594 der to compute these deformations, we sample so-called handle regions on the membrane surface. 595 These regions are translated in a random, normal or negative normal direction. The deformation 596 constraint is then propagated to the rest of the surface either via a biharmonic deformation field 597 or an as-rigid-as-possible deformation. We combine these deformations with random anisotropic 598 scaling, rotations and/or symmetry transformations. 599 To create positive samples for the contrastive training of texture we used random flips and rota600 tions and elastic transformations of the data. 601 Inference 602 In order to compute the MorphoFeatures representation for the whole animal, we processed each 603 cell’s cellular and nuclear shape and texture, as described in previous sections, with our trained 23 f 35 604 network. Each cell is represented by a 480-dimensional vector that consists of a nuclear and cellu605 lar part. Each of these parts consists of a shape, coarse and fine-grained texture 80-dimensional 606 feature vector. 607 Quantitative feature evaluation 608 In this section we describe our feature evaluation experiments in more detail. In order to assess 609 the quality of MorphoFeatures quantitatively we conducted cell-type prediction and bilateral pair 610 analysis experiments. We use the same set of explicit features that were used in _Vergara_ _et_ _al._ 611 ( _2021_ ) for analysing cellular morphology as a baseline for comparisons. 612 Explicit feature baseline 613 The explicitly defined representation includes shape features (volume in microns, extent, equiv614 ariant diameter, major & minor axes, surface area, sphericity, max radius), intensity features (dif615 ferent quantiles of intensity mean, median and standard deviation) and Haralick texture features. 616 These features were calculated, whenever appropriate, for cell cytoplasm, nucleus and chromatin 617 segmentation. [The calculated features were taken from https://github.com/mobie/platybrowser-pr](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology.tsv) 618 [oject/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology.tsv](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology.tsv) for cellular 619 [segmentation and from https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-nuclei/morphology.tsv) 620 [sbem-6dpf-1-whole-segmented-nuclei/morphology.tsv for nucleus and chromatin segmentation.](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-nuclei/morphology.tsv) The 621 [UMAP of these features was taken from https://github.com/mobie/platybrowser-project/blob/main/](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology_umap.tsv) 622 [data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology_umap.tsv.](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology_umap.tsv) 623 Classification of visibly distinct groups of cells 624 In order to verify that MorphoFeatures can distinguish visibly different groups of cells, we evaluated 625 the prediction accuracy of a logistic regression model that was trained on a small dataset of 390 626 annotated cells taken from _Vergara_ _et_ _al._ ( _2021_ ) (Figure 2A). The original annotation contained 627 571 neurons, 141 epithelial cells, 55 midgut cells, 53 muscle cells, 51 secretory cells, 41 dark cells 628 and 25 ciliated cells. We first corrected some cells with clearly wrong assignments. Then for the 629 classes that contained less than 60 cells we manually annotated more cells. From bigger classes 630 we selected 60 cells, selecting the most morphologically diverse ones when possible. For ciliated 631 cells we were only able to locate 30 cells in the whole animal. 632 First we computed the MorphoFeatures representation for each cell in the animal (excluding cells 633 with severe segmentation errors) and standardised features across the whole dataset. We then 634 trained and validated a logistic regression model using a stratified k-folds cross validator with 5 635 folds. We used the implementations of logistic regression, stratified k-fold from Scikit-learn ( _Pe-_ 636 _dregosa et al., 2011_ ) with the following arguments: C=1, solver=’lbfgs’. To prevent potential over637 fitting due to the high number of features we used feature agglomeration ( _Pedregosa et al., 2011_ ) 638 (n_clusters=100) to reduce the amount of similar features. 639 Bilateral pair analysis 640 The criterion of classifying distinct groups of cells in the previous section can be seen as a coarse 641 and global way of evaluating MorphoFeatures. In this section we describe how we used the an642 imal’s bilateral symmetry to have a more fine-grained measure for quantitatively evaluating nu643 anced morphological differences. The measure, which we will refer to as bilateral distance, was 644 introduced in _Vergara et al._ ( _2021_ ) and leverages the fact that most cells in the animal have a sym645 metric partner cell on the other side of the mediolateral axis. The bilateral distance is computed in 646 the following way: first, we determine for each cell _?_ a group of N potential partner cells { _?_ 1 _, ..., ??_ } 647 on the opposite side. We then compute a ranking based on the Euclidean distances ‖ _?_ - _?_ <sup>′</sup> ‖ in 648 feature space between cell _?_ and all other cells _?_ <sup>′</sup> ≠ _?_ . Since _?_ ’s symmetric partner has the same 649 morphology, up to natural variability, it should be among the closest cells in the ranking. We then 650 determine the highest ranked partner cell as rank(‖ _?_ - _??_ ‖). In doing this for all cells, we create 24 f 35 651 a list containing the ranking positions of cells to their symmetric partner. The bilateral distance 652 is then defined as the median of this list and can be interpreted as a measure of how close two 653 morphologically very similar cells are on average in feature space. 654 Adding neighbour morphological information 655 This section describes how neighbourhood information was incorporated into MorphFeatures in 656 order to obtain MorphoContextFeatures. First we built a region adjacency graph from the cell seg657 mentation masks using scikit-image ( _Van_ _der_ _Walt_ _et_ _al.,_ _2014_ ). The obtained graph reflects the 658 animal’s cellular connectivity, i.e. cells are represented by nodes in the graph and nodes are con659 nected by an edge if the corresponding cells are neighbours. We then assign node attributes by 660 mapping the MorphoFeatures representation of a cell to the corresponding node. Neighbourhood 661 features are then obtained by computing the mean over a node’s MorphoFeatures vector and the 662 MorphoFeatures vectors of its surrounding neighbours. Finally, a cell’s neighbourhood features 663 are concatenated with the cell’s MorphoFeatures to obtain the MorphoContextFeatures represen664 tation. 665 Feature analysis 666 Visualising features 667 In order to visualise the features extracted by our pipeline (Figure 3) we manually selected a set of 668 features that visually corresponded to potentially interpretable textures/shapes and showed their 669 extremes with cells that have the respective minimal/maximal value of this feature. The cells with 670 obvious segmentation errors that resulted in incorrect shapes or textures were ignored. In order 671 to visualise the 3D cells and nuclei we selected a 2D view that we presume shows the shape or 672 texture feature common between all 4 selected cells with minimal or maximal value of the feature. 673 UMAP representation analysis 674 Visualisation was done using the UMAP package ( _McInnes et al._ ( _2018_ )) with the following param675 eters: euclidean metric, 15 neighbours and 0 minimal distance. Cell metadata, such as annotated 676 types, animal regions or gene expression were plotted on the resulting UMAP. 677 Clustering 678 Cell clustering was done according to the following procedure. First the features were standard679 ised to zero mean and unit variance. Then, following ( _Dubourg-Felonneau et al., 2021_ ) a weighted 680 k-neighbour graph was constructed from MorphoFeatures representations of all the animal cells 681 using the UMAP algorithm ( _McInnes_ _et_ _al.,_ _2018_ ) with the following arguments: n_neighbors=20, 682 metric=’euclidean’, min_dist=0. Afterwards the Leiden algorithm ( _Traag et al., 2019_ ) for community 683 detection was used to partition the resulting graph, using the CPMVertexPartition method and a 684 resolution parameter of 0.004. This resulted in 16 clusters, one of which was discarded, since it 685 contained only cells with split segmentation errors. For more fine-grained clustering the resolu686 tion was increased to 0.1 to split apart secretory and ciliary band cells, 0.2 to split photorecep687 tors and enteric neurons, 0.07 to split the midgut cluster, 0.005 for muscle neighbourhood cluster 688 (n_neighbors for the UMAP clustering was adjusted to 10) and 0.01 for splitting foregut neurons 689 and epithelial cells. To visualise average shape and texture of a cluster (5B,C), a median feature 690 vector was computed across the cluster and the cell with the feature vector closest to the median 691 one was taken as the average cell. 692 Gene expression analysis 693 To produce the cluster gene expression ‘dot plots’ (Figure 5A, 6B, 8C, 9E) the gene expression values 694 for each cell were taken from _Vergara et al._ ( _2021_ [) at https://github.com/mobie/platybrowser-project/](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/genes.tsv) 695 [blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/genes.tsv.](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/genes.tsv) Similar to _Vergara et al._ 696 ( _2021_ ), for each cluster and for each gene we calculated three values: (A) the mean expression in 25 f 35 697 the cluster, (B) the fraction of the total animal/region expression within this cluster (the sum of 698 expression in this cluster divided by the sum of the expression in the whole animal or the selected 699 region) and (C) the specificity defined as _?_ = 2 _??_ ∕( _?_ + _?_ ). Intuitively, _?_ indicates how much of the 700 cells in a given cluster express a given gene, _?_ shows how selective this gene for this cluster is and 701 _?_ is a harmonic mean of the two values. To create a dot plot only the genes with _?_ value above 0.15 702 were used. For the neuron clusters 1, 3 and 5 (Figure 5A) the threshold was increased to 0.2 due to 703 a high number of specifically expressed genes available. For the midgut clusters (Figure 6) to show 704 only the genes differing between the two clusters, the genes were removed, where the specificity 705 was above 0.15 in both clusters, but differed by less than 0.4. The size of dots in the plots reflects 706 _?_ and the colour corresponds to _?_ . The cluster with the most gene expression was determined 707 and the remaining clusters were sorted by their similarity to it. To illustrate some of the genes 708 showing differential expression in these groups (Figure 5, 8, 9), the corresponding regions of the 709 UMAP representation were cut out and these genes were plotted on top. 710 Ganglionic nuclei 711 [To compare ganglionic nuclei (Figure 8) we used manually segmented regions from https://github](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/ganglia_ids.tsv) 712 [.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/ga](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/ganglia_ids.tsv) 713 [nglia_ids.tsv and https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/ganglia_ids.tsv) 714 [dpf-1-whole-segmented-cells/regions.tsv and gene clusters from https://github.com/mobie/platybrowse](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/regions.tsv) 715 [r-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/gene_clusters.tsv (](https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/gene_clusters.tsv) _Vergara_ 716 _et al._ ( _2021_ )). 717 Data visualisation 718 We used matplotlib ( _Hunter, 2007_ ) and seaborn ( _Waskom, 2021_ ) for plotting the data, MoBIE ( _Ver-_ 719 _gara et al., 2021_ ) for visualising cells in the EM volume and vedo ( _Musy et al., 2022_ ) for visualising 720 meshed cells and tissues. 721 Acknowledgments 722 We thank all the members of the Kreshuk and Uhlmann group, especially Constantin Pape, for 723 helpful comments. We further thank Christian Tischer for implementing features essential for bi724 ological analysis and exploration in MoBIE. We thank Hernando M. Vergara for assistance in cell 725 type recognition and Kimberly I. Meechan for help with comparison to explicit features. We would 726 also like to acknowledge the support of the EMBL IT Services, especially Juri Pecar for maintaining 727 the GPU resources. The work was supported by EMBL internal funds, and by a grant from the 728 European Research Council (NeuralCellTypeEvo 788921) to D.A. 729 References 730 Arendt D . The evolution of cell types in animals: emerging principles from molecular studies. Nature Reviews 731 Genetics. 2008; 9(11):868–882. 732 Arendt D . Elementary nervous systems. Philosophical Transactions of the Royal Society B. 2021; 733 376(1821):20200347. 734 Arendt D, Bertucci PY, Achim K, Musser JM. Evolution of neuronal types and families. Current opinion in 735 neurobiology. 2019; 56:144–152. 736 Arendt D, Musser JM, Baker CV, Bergman A, Cepko C, Erwin DH, Pavlicev M, Schlosser G, Widder S, Laubichler 737 MD, et al. The origin and evolution of cell types. Nature Reviews Genetics. 2016; 17(12):744–757. 738 Backfisch B . Regulatory tools and the characterization of insulinergic cells in the annelid Platynereis dumerilii. 739 na; 2013. 740 Bae JA, Baptiste M, Bodor AL, Brittain D, Buchanan J, Bumbarger DJ, Castro MA, Celii B, Cobos E, Collman F, et al. 741 Functional connectomics spanning multiple areas of mouse visual cortex. bioRxiv. 2021; . 26 f 35 742 Barad BA, Medina M, Fuentes D, Wiseman RL, Grotjahn DA. A surface morphometrics toolkit to quantify or743 ganellar membrane ultrastructure using cryo-electron tomography. bioRxiv. 2022; . 744 Baskin DG . Further observations on the fine structure and development of the infracerebral complex (“infrac745 erebral gland”) of Nereis limnicola (Annelida, Polychaeta). Cell and Tissue Research. 1974; 154(4):519–531. 746 Botsch M, Kobbelt L. An intuitive framework for real-time freeform modeling. ACM Transactions on Graphics 747 (TOG). 2004; 23(3):630–634. 748 Boyle MJ, Seaver EC. Developmental expression of foxA and gata genes during gut formation in the polychaete 749 annelid, Capitella sp. I. Evolution & development. 2008; 10(1):89–105. 750 Brunet T, Fischer AH, Steinmetz PR, Lauri A, Bertucci P, Arendt D. The evolutionary origin of bilaterian smooth 751 and striated myocytes. Elife. 2016; 5:e19607. 752 Caicedo JC, McQuin C, Goodman A, Singh S, Carpenter AE. Weakly supervised learning of single-cell feature 753 embeddings. In: _Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition_ ; 2018. p. 9309– 754 9318. 755 Chen T, Kornblith S, Norouzi M, Hinton G. A simple framework for contrastive learning of visual representations. 756 In: _International conference on machine learning_ PMLR; 2020. p. 1597–1607. 757 Cignoni P, Callieri M, Corsini M, Dellepiane M, Ganovelli F, Ranzuglia G, et al. Meshlab: an open-source mesh 758 processing tool. In: _Eurographics Italian chapter conference_, vol. 2008 Salerno, Italy; 2008. p. 129–136. 759 Clevert DA, Unterthiner T, Hochreiter S. Fast and accurate deep network learning by exponential linear units 760 (elus). arXiv preprint arXiv:151107289. 2015; . 761 Cole A, Arnone M. Fluorescent in situ hybridization reveals multiple expression domains for SpBrn1/2/4 and 762 identifies a unique ectodermal cell type that co-expresses the ParaHox gene SpLox. Gene Expression Pat763 terns. 2009; 9(5):324–328. 764 Cook SJ, Jarrell TA, Brittin CA, Wang Y, Bloniarz AE, Yakovlev MA, Nguyen KC, Tang LTH, Bayer EA, Duerr JS, et al. 765 Whole-animal connectomes of both Caenorhabditis elegans sexes. Nature. 2019; 571(7763):63–71. 766 Doan M, Sebastian JA, Caicedo JC, Siegert S, Roch A, Turner TR, Mykhailova O, Pinto RN, McQuin C, Goodman A, 767 et al. Objective assessment of stored blood quality by deep learning. Proceedings of the National Academy 768 of Sciences. 2020; 117(35):21381–21390. 769 Driscoll MK, Welf ES, Jamieson AR, Dean KM, Isogai T, Fiolka R, Danuser G. Robust and automated detection 770 of subcellular morphological motifs in 3D microscopy images. Nature methods. 2019; 16(10):1037–1044. 771 Dubourg-Felonneau G, Shams S, Akiva E, Lee L. Protein Organization with Manifold Exploration and Spectral 772 Clustering. bioRxiv. 2021; . 773 Eulenberg P, Köhler N, Blasi T, Filby A, Carpenter AE, Rees P, Theis FJ, Wolf FA. Reconstructing cell cycle and 774 disease progression using deep learning. Nature communications. 2017; 8(1):1–6. 775 Falk T, Mai D, Bensch R, Çiçek Ö, Abdulkadir A, Marrakchi Y, Böhm A, Deubner J, Jäckel Z, Seiwald K, et al. U-Net: 776 deep learning for cell counting, detection, and morphometry. Nature methods. 2019; 16(1):67–70. 777 Fincher CT, Wurtzel O, de Hoog T, Kravarik KM, Reddien PW. Cell type transcriptome atlas for the planarian 778 Schmidtea mediterranea. Science. 2018; 360(6391):eaaq1736. 779 Girshick R, Donahue J, Darrell T, Malik J. Rich feature hierarchies for accurate object detection and semantic 780 segmentation. In: _Proceedings of the IEEE conference on computer vision and pattern recognition_ ; 2014. p. 580– 781 587. 782 Golding D . The infracerebral gland in Nephtys—a possible neuroendocrine complex. General and Comparative 783 Endocrinology. 1970; 14(1):114–126. 784 Grill JB, Strub F, Altché F, Tallec C, Richemond P, Buchatskaya E, Doersch C, Avila Pires B, Guo Z, Gheshlaghi Azar 785 M, et al. Bootstrap your own latent-a new approach to self-supervised learning. Advances in Neural Infor786 mation Processing Systems. 2020; 33:21271–21284. 787 Hadsell R, Chopra S, LeCun Y. Dimensionality reduction by learning an invariant mapping. In: _2006 IEEE Com-_ 788 _puter Society Conference on Computer Vision and Pattern Recognition (CVPR’06)_, vol. 2 IEEE; 2006. p. 1735–1742. 27 f 35 789 Hassani K, Khasahmadi AH. Contrastive multi-view representation learning on graphs. In: _International_ _Con-_ 790 _ference on Machine Learning_ PMLR; 2020. p. 4116–4126. 791 He K, Fan H, Wu Y, Xie S, Girshick R. Momentum contrast for unsupervised visual representation learning. In: 792 _Proceedings of the IEEE/CVF conference on computer vision and pattern recognition_ ; 2020. p. 9729–9738. 793 Heinrich L, Bennett D, Ackerman D, Park W, Bogovic J, Eckstein N, Petruncio A, Clements J, Pang S, Xu CS, et al. 794 Whole-cell organelle segmentation in volume electron microscopy. Nature. 2021; 599(7883):141–146. 795 Hobert O . Terminal selectors of neuronal identity. Current topics in developmental biology. 2016; 116:455– 796 475. 797 Hobert O, Kratsios P. Neuronal identity control by terminal selectors in worms, flies, and chordates. Current 798 Opinion in Neurobiology. 2019; 56:97–105. 799 Hofmann D . Regeneration and endocrinology in the polychaetePlatynereis dumerilii. Wilhelm Roux’s archives 800 of developmental biology. 1976; 180(1):47–71. 801 Huang GB, Yang HF, Takemura Sy, Rivlin P, Plaza SM. Latent feature representation via unsupervised learning 802 for pattern discovery in massive electron microscopy image volumes. arXiv preprint arXiv:201212175. 2020; 803 . 804 Hunter JD . Matplotlib: A 2D graphics environment. Computing in science & engineering. 2007; 9(03):90–95. 805 Jacobson A, Panozzo D, Schüller C, Diamanti O, Zhou Q, Pietroni N, et al., libigl: A simple C++ geometry pro806 cessing library; 2018. 807 Kingma DP, Ba J. Adam: A method for stochastic optimization. arXiv preprint arXiv:14126980. 2014; . 808 Kobayashi H, Cheveralls KC, Leonetti MD, Royer LA. Self-Supervised Deep Learning Encodes High-Resolution 809 Features of Protein Subcellular Localization. bioRxiv. 2021; . 810 Krizhevsky A, Sutskever I, Hinton GE. Imagenet classification with deep convolutional neural networks. Ad811 vances in neural information processing systems. 2012; 25. 812 Kuan AT, Phelps JS, Thomas LA, Nguyen TM, Han J, Chen CL, Azevedo AW, Tuthill JC, Funke J, Cloetens P, et al. 813 Dense neuronal reconstruction through X-ray holographic nano-tomography. Nature neuroscience. 2020; 814 23(12):1637–1643. 815 Lafarge MW, Caicedo JC, Carpenter AE, Pluim JP, Singh S, Veta M. Capturing single-cell phenotypic variation 816 via unsupervised representation learning. In: _International Conference on Medical Imaging with Deep Learning_ 817 PMLR; 2019. p. 315–325. 818 Lauri A, Brunet T, Handberg-Thorsager M, Fischer AH, Simakov O, Steinmetz PR, Tomer R, Keller PJ, Arendt D. 819 Development of the annelid axochord: insights into notochord evolution. Science. 2014; 345(6202):1365– 820 1368. 821 Li G, Muller M, Thabet A, Ghanem B. Deepgcns: Can gcns go as deep as cnns? In: _Proceedings of the IEEE/CVF_ 822 _international conference on computer vision_ ; 2019. p. 9267–9276. 823 Lorensen WE, Cline HE. Marching cubes: A high resolution 3D surface construction algorithm. ACM siggraph 824 computer graphics. 1987; 21(4):163–169. 825 Lu AX, Kraus OZ, Cooper S, Moses AM. Learning unsupervised feature representations for single cell mi826 croscopy images with paired cell inpainting. PLoS computational biology. 2019; 15(9):e1007348. 827 Macrina T, Lee K, Lu R, Turner NL, Wu J, Popovych S, Silversmith WW, Kemnitz N, Bae JA, Castro MA, et al. 828 Petascale neural circuit reconstruction: automated methods. bioRxiv. 2021; . 829 Maitin-Shepard J, Baden A, Silversmith W, Perlman E, Collman F, Blakely T, Funke J, Jordan C, Falk B, Kem830 nitz N, tingzhao, Roat C, Castro M, Jagannathan S, moenigin, Clements J, Hoag A, Katz B, Parsons D, Wu J, 831 et al., google/neuroglancer:. Zenodo; 2021. [https://doi.org/10.5281/zenodo.5573294,](https://doi.org/10.5281/zenodo.5573294) doi: 10.5281/zen832 odo.5573294. 833 McInnes L, Healy J, Melville J. Umap: Uniform manifold approximation and projection for dimension reduction. 834 arXiv preprint arXiv:180203426. 2018; . 28 f 35 835 Müller A, Schmidt D, Xu CS, Pang S, D’Costa JV, Kretschmar S, Münster C, Kurth T, Jug F, Weigert M, et al. 3D 836 FIB-SEM reconstruction of microtubule–organelle interaction in whole primary mouse _?_ cells. Journal of Cell 837 Biology. 2021; 220(2). 838 Musser JM, Schippers KJ, Nickel M, Mizzon G, Kohn AB, Pape C, Ronchi P, Papadopoulos N, Tarashansky AJ, 839 Hammel JU, et al. Profiling cellular diversity in sponges informs animal cell type and nervous system evolution. 840 Science. 2021; 374(6568):717–723. 841 Musy M, Jacquenot G, Dalmasso G, neoglez, de Bruin R, Pollack A, Claudi F, Badger C, icemtel, Zhou ZQ, Sullivan 842 B, Lerner B, Hrisca D, Volpatto D, marcomusy/vedo: 2022.1.0. Zenodo; 2022. [https://doi.org/10.5281/zenodo](https://doi.org/10.5281/zenodo.6247803) 843 [.6247803, doi:](https://doi.org/10.5281/zenodo.6247803) 10.5281/zenodo.6247803. 844 Nielsen C, Brunet T, Arendt D. Evolution of the bilaterian mouth and anus. Nature ecology & evolution. 2018; 845 2(9):1358–1376. 846 Van den Oord A, Li Y, Vinyals O. Representation learning with contrastive predictive coding. arXiv e-prints. 847 2018; p. arXiv–1807. 848 Pape C, Beier T, Li P, Jain V, Bock DD, Kreshuk A. Solving large multicut problems for connectomics via domain 849 decomposition. In: _Proceedings_ _of_ _the_ _IEEE_ _International_ _Conference_ _on_ _Computer_ _Vision_ _Workshops_ ; 2017. p. 850 1–10. 851 Paszke A, Gross S, Massa F, Lerer A, Bradbury J, Chanan G, Killeen T, Lin Z, Gimelshein N, Antiga L, et al. Pytorch: 852 An imperative style, high-performance deep learning library. Advances in neural information processing 853 systems. 2019; 32. 854 Pedregosa F, Varoquaux G, Gramfort A, Michel V, Thirion B, Grisel O, Blondel M, Prettenhofer P, Weiss R, 855 Dubourg V, et al. Scikit-learn: Machine learning in Python. the Journal of machine Learning research. 2011; 856 12:2825–2830. 857 Phillip JM, Han KS, Chen WC, Wirtz D, Wu PH. A robust unsupervised machine-learning method to quantify the 858 morphological heterogeneity of cells and nuclei. Nature protocols. 2021; 16(2):754–774. 859 Pietzsch T, Saalfeld S, Preibisch S, Tomancak P. BigDataViewer: visualization and processing for large image 860 data sets. Nature methods. 2015; 12(6):481–483. 861 Ronneberger O, Fischer P, Brox T. U-net: Convolutional networks for biomedical image segmentation. In: 862 _International Conference on Medical image computing and computer-assisted intervention_ Springer; 2015. p. 234– 863 241. 864 Ruan X, Johnson GR, Bierschenk I, Nitschke R, Boerries M, Busch H, Murphy RF. Image-derived models of 865 cell organization changes during differentiation and drug treatments. Molecular biology of the cell. 2020; 866 31(7):655–666. 867 Scheffer LK, Xu CS, Januszewski M, Lu Z, Takemura Sy, Hayworth KJ, Huang GB, Shinomiya K, Maitlin-Shepard 868 J, Berg S, et al. A connectome and analysis of the adult Drosophila central brain. Elife. 2020; 9:e57443. 869 Schindelin J, Arganda-Carreras I, Frise E, Kaynig V, Longair M, Pietzsch T, Preibisch S, Rueden C, Saalfeld S, 870 Schmid B, et al. Fiji: an open-source platform for biological-image analysis. Nature methods. 2012; 9(7):676– 871 682. 872 Schroeder W, Martin KM, Lorensen WE. The visualization toolkit an object-oriented approach to 3D graphics. 873 Prentice-Hall, Inc.; 1998. 874 Schubert PJ, Dorkenwald S, Januszewski M, Jain V, Kornfeld J. Learning cellular morphology with neural net875 works. Nature communications. 2019; 10(1):1–12. 876 Sebé-Pedrós A, Chomsky E, Pang K, Lara-Astiaso D, Gaiti F, Mukamel Z, Amit I, Hejnol A, Degnan BM, Tanay 877 A. Early metazoan cell type diversity and the evolution of multicellular gene regulation. Nature ecology & 878 evolution. 2018; 2(7):1176–1188. 879 Sebé-Pedrós A, Saudemont B, Chomsky E, Plessier F, Mailhé MP, Renno J, Loe-Mie Y, Lifshitz A, Mukamel Z, 880 Schmutz S, et al. Cnidarian cell type diversity and regulation revealed by whole-organism single-cell RNA881 Seq. Cell. 2018; 173(6):1520–1534. 882 Siebert S, Farrell JA, Cazet JF, Abeykoon Y, Primack AS, Schnitzler CE, Juliano CE. Stem cell differentiation trajec883 tories in Hydra resolved at single-cell resolution. Science. 2019; 365(6451):eaav9314. 29 f 35 884 Simonyan K, Zisserman A. Very deep convolutional networks for large-scale image recognition. arXiv preprint 885 arXiv:14091556. 2014; . 886 Song S, Starunov V, Bailly X, Ruta C, Kerner P, Cornelissen AJ, Balavoine G. Globins in the marine annelid 887 Platynereis dumerilii shed new light on hemoglobin evolution in bilaterians. BMC evolutionary biology. 2020; 888 20(1):1–23. 889 Sorkine O, Alexa M. As-rigid-as-possible surface modeling. In: _Symposium on Geometry processing_, vol. 4; 2007. 890 p. 109–116. 891 Stine RR, Sakers AP, TeSlaa T, Kissig M, Stine ZE, Kwon CW, Cheng L, Lim HW, Kaestner KH, Rabinowitz JD, et al. 892 PRDM16 maintains homeostasis of the intestinal epithelium by controlling region-specific metabolism. Cell 893 Stem Cell. 2019; 25(6):830–845. 894 Stutz D, Geiger A. Learning 3d shape completion under weak supervision. International Journal of Computer 895 Vision. 2020; 128(5):1162–1181. 896 Tanay A, Sebé-Pedrós A. Evolutionary cell type mapping with single-cell genomics. Trends in Genetics. 2021; 897 37(10):919–932. 898 Tian Y, Krishnan D, Isola P. Contrastive multiview coding. In: _European conference on computer vision_ Springer; 899 2020. p. 776–794. 900 Traag VA, Waltman L, Van Eck NJ. From Louvain to Leiden: guaranteeing well-connected communities. Scientific 901 reports. 2019; 9(1):1–12. 902 Turner NL, Macrina T, Bae JA, Yang R, Wilson AM, Schneider-Mizell C, Lee K, Lu R, Wu J, Bodor AL, et al. Recon903 struction of neocortex: Organelles, compartments, cells, circuits, and activity. Cell. 2022; 185(6):1082–1100. 904 Velickovic P, Fedus W, Hamilton WL, Liò P, Bengio Y, Hjelm RD. Deep Graph Infomax. ICLR (Poster). 2019; 905 2(3):4. 906 Verasztó C, Jasek S, Gühmann M, Shahidi R, Ueda N, Beard JD, Mendes S, Heinz K, Bezares-Calderón LA, Williams 907 E, Jékely G. Whole-animal connectome and cell-type complement of the three-segmented Platynereis dumer908 ilii larva. bioRxiv. 2020; [https://www.biorxiv.org/content/early/2020/08/23/2020.08.21.260984,](https://www.biorxiv.org/content/early/2020/08/23/2020.08.21.260984) doi: 909 10.1101/2020.08.21.260984. 910 Vergara HM, Pape C, Meechan KI, Zinchenko V, Genoud C, Wanner AA, Mutemi KN, Titze B, Templin RM, Bertucci 911 PY, et al. Whole-body integration of gene expression and single-cell morphology. Cell. 2021; 184(18):4819– 912 4837. 913 Van der Walt S, Schönberger JL, Nunez-Iglesias J, Boulogne F, Warner JD, Yager N, Gouillart E, Yu T. scikit-image: 914 image processing in Python. PeerJ. 2014; 2:e453. 915 Waskom ML . Seaborn: statistical data visualization. Journal of Open Source Software. 2021; 6(60):3021. 916 White AJ, Northcutt MJ, Rohrback SE, Carpenter RO, Niehaus-Sauter MM, Gao Y, Wheatly MG, Gillen CM. Char917 acterization of sarcoplasmic calcium binding protein (SCP) variants from freshwater crayfish Procambarus 918 clarkii. Comparative Biochemistry and Physiology Part B: Biochemistry and Molecular Biology. 2011; 160(1):8– 919 14. 920 Yao K, Rochman ND, Sun SX. Cell type classification and unsupervised morphological phenotyping from low921 resolution images using deep learning. Scientific reports. 2019; 9(1):1–13. 922 Zeng H, Sanes JR. Neuronal cell-type classification: challenges, opportunities and the path forward. Nature 923 Reviews Neuroscience. 2017; 18(9):530–546. 924 Zheng Z, Lauritzen JS, Perlman E, Robinson CG, Nichols M, Milkie D, Torrens O, Price J, Fisher CB, Sharifi N, 925 et al. A complete electron microscopy volume of the brain of adult Drosophila melanogaster. Cell. 2018; 926 174(3):730–743. 30 f 35 927 Supplementary ### A B L: Epithelial cell P: Neuron cell L: Muscle cell P: Midgut cell L: Secretory cell P: Epithelial cell L: Epithelial cell P: Secretory cell L: Muscle cell P: Neuron cell L: Secretory cell P: Muscle cell L: Epithelial celll P: Secretory cell L: Secretory cell P: Midgut cell L: Secretory cell P: Muscle cell L: Neuron cell P: Epithelial cell L: Secretory cell P: Epithelial cell L: Secretory cell P: Muscle. cell L: Neurosecr. cell P: Neuron cell L: Secretory cell P: Epithelial cell L: Midgut cell P: Epithelial cell 1.0 0.5 0.0 Figure S1. Morphological class predictions. A. All the errors made during any of the cross-validation runs of the logistic regression model (L – True Label, P – Prediction, scale bars: 5 _?_ m). B. Whole-animal prediction of (from left to right) dark neurosecretory, muscle, secretory, ciliary band and midgut cells (scale bars: 25 _?_ m). 31 f 35 ap2 nk6 for mthfsd 2 3 4 nb5r3 trpv 4 ache boule-like calmodulin mhcl4 brn124 pcdh15 pkd1 sim1 pkd2 trpv4 dlx fvri 3 1 5 5 1 2 globin like mitf Figure S2. Clustering and gene analysis. Some of the genes shown to be differentially expressed in neuron, midgut, muscle and epithelial clusters and in the photoreceptor cells are visualised on the UMAP representation. 32 f 35 A B C Cell types Not labeled Epithelial cells Neuron cells Neurosecr. cells Muscle cells Secretory cells Ciliary band cells Midgut cells D Rhabdomeric photoreceptors Cluster of foregut muscles Enteric neurons Figure S3. Comparing MorphoFeatures to a set of manually defined features from _Vergara et al._ ( _2021_ ). A. The set of manually defined features is visualized in 2D using UMAP. The cells for which annotations are available are visualized in respective colors. BC. The MorphoFeatures cluster of ( B ) the rhabdomeric photoreceptors and ( C ) enteric neurons is visualised on the UMAP representation of the manually defined features, showing a bigger spread of cells across the morphological space. D. The MorphoFeatures cluster of the foregut muscles is split into multiple groups on the UMAP representation of the manually defined features. For two groups, cells are visualised in the animal volume, showing similarity of the cells comprising them. 33 f 35 ## A B C 34 f 35 Figure S4. Infracerebral gland. A. The location of the gland in the head. The neuropil and the secretory cells are pointed up by black arrows, the surrounding muscle layers - by red arrows. B. The shape of the gland and its position relative to the posterior pair of adult eyes (black arrows). C. A cavity likely to be a developing blood vessel (black arrow) on top of the gland. 35 f 35

섹션 본문 145문단 · 142,980자

(제목 없음)

1Electron microscopy (EM) provides a uniquely detailed view of cellular morphology, including organelles and fine subcellular ultrastructure. While the acquisition and (semi-)automatic segmentation of multicellular EM volumes are now becoming routine, large-scale analysis remains severely limited by the lack of generally applicable pipelines for automatic extraction of comprehensive morphological descriptors. Here, we present a novel unsupervised method for learning cellular morphology features directly from 3D EM data: a neural network delivers a representation of cells by shape and ultrastructure. Applied to the full volume of an entire three-segmented worm of the annelid Platynereis dumerilii, it yields a visually consistent grouping of cells supported by specific gene expression profiles. Integration of features across spatial neighbours can retrieve tissues and organs, revealing, for example, a detailed organisation of the animal foregut. We envision that the unbiased nature of the proposed morphological descriptors will enable rapid exploration of very different biological questions in large EM volumes, greatly increasing the impact of these invaluable, but costly resources.Editor's evaluationThis paper marks a fundamental advance in reconstruction of volume EM images, by introducing the automatic assignment of cell types and tissues. This task has previously been done manually, resulting in a serious bottleneck in reconstruction, but the authors present compelling evidence that in at least some cases, automatic and semi-automatic techniques can match or better human assignment of cell and tissue types. These results will be of interest to almost all groups doing EM reconstruction, as they can speed up cell type assignment when the cell types are known, and provide an initial cell type and tissue classification when they are not.

Introduction

2Development of multicellular organisms progressively gives rise to a variety of cell types, with differential gene expression resulting in different cellular structures that enable diverse cellular functions. Structures and functions together represent the phenotype of an organism. The characterisation of cell types is important to understand how organisms are built and function in general (Arendt, 2008). Recent advances in single-cell sequencing have allowed the monitoring of differential gene expression in the cell types that make up the tissues and organs of entire multicellular organisms and led to the recognition of distinct regulatory programmes driving the expression of unique sets of cell type-specific effector genes (Hobert and Kratsios, 2019;Sebé-Pedrós et al., 2018a;Sebé-Pedrós et al., 2018b;Musser et al., 2021;Fincher et al., 2018;Siebert et al., 2019). These distinct genetic programmes make the identity and thus define cell types Tanay and Sebé-Pedrós, 2021). The genetic individuation of cell types then translates into phenotypic differences between cells, and one of the most intriguing questions is to determine this causation for each cell type. Only then will we understand their structural and functional peculiarities and intricacies and learn how evolutionary cell type diversification has sustained organismal morphology and physiology. As a prerequisite towards this aim, we need a comprehensive monitoring and comparison of cellular phenotypes across the entire multicellular body, which can then be linked to the genetically defined cell types.

3Recent efforts have focused on large-scale high-resolution imaging to capture the morphological uniqueness of cell types. For the first time, the rapid progress in volume EM allows this for increasingly large samples, including organs and entire smaller animals, with nanometer resolution Vergara et al., 2021;Zheng et al., 2018;Scheffer et al., 2020;Cook et al., 2019;Verasztó et al., 2020). Supported by automated cell segmentation pipelines (Heinrich et al., 2021;Macrina et al., 2021;Pape et al., 2017;Müller et al., 2021), such datasets allow characterisation and comparison of cellular morphologies, including membrane-bound and membraneless organelles and inclusions, at an unprecedented level of detail for thousands of cells simultaneously (Turner et al., 2022;Vergara et al., 2021). A notable challenge of such large-scale studies is the analysis of massive amounts of imaging data that can no longer be inspected manually. The latest tools for visual exploration of multi-terabyte 3D data allow for seamless browsing through the regions of interest (Pietzsch et al., 2015;Maitin-Shepard et al., 2021), given such regions are specified and contain a limited number of cells. However, if the goal is to characterise and/or compare morphologies of most or all cells in the dataset, one has to be able to automatically assign each cell an unbiased comprehensive morphological description -a feature vector with values representing the morphological properties of the cell in the most parsimonious manner.

4The need for automation and quantitative evaluation has triggered the design of complex engineered features that capture specific cell characteristics (Barad et al., 2022). However, such features often have to be manually chosen and mostly provide only a limited, targeted view of the overall morphology. To alleviate this problem, intricate modelling pipelines for cellular morphology quantification have been developed (Ruan et al., 2020;Driscoll et al., 2019;Phillip et al., 2021); still, these are often data-and task-specific. For unbiased monitoring and comparison of cellular morphologies, broadly applicable automated pipelines are missing. They should, in addition, be capable of extracting comprehensive representations that are not biased by manual feature selection, the end task, or the type of data used. We expect that developing such techniques will not only speed up the process of scientific discovery in big volume imaging datasets but also facilitate detecting unusual and underrepresented morphologies.

5In the last decade, artificial neural networks have been shown to exceed manually engineered pipelines in extracting comprehensive descriptors for various types of data and to be particularly suited for the extraction of visual features (Krizhevsky et al., 2012;Falk et al., 2019;Simonyan and Zisserman, 2014;Girshick et al., 2014). Moreover, the rise of so-called self-supervised training methods has removed the necessity for generating massive amounts of manual annotations previously needed to train a network. Besides the obvious advantage of being less labour-intensive, selfsupervised methods do not optimise features for a specific end-task but instead produce descriptors that have been shown to be useful in a variety of downstream tasks, such as image classification, segmentation, and object detection (He et al., 2020;Van den Oord et al., 2018;Tian et al., 2020). Such methods have already shown to be successful for phenotyping cells in image-based profiling (Lu et al., 2019;Lafarge et al., 2019) and for describing local morphology of patches or subcompartments within neural cells in 3D electron microscopy (EM) of brain volumes Schubert et al., 2019). Building on the latest achievements, we aim to expand the feature extraction methods to automated characterisation of cellular morphology at the whole animal level.

6Here, we present the first framework for the fully unsupervised characterisation of cellular shapes and ultrastructures in a whole-body dataset for an entire animal. We apply this new tool to the fully segmented serial block-face EM (SBEM) volume of the 6 days post fertilisation young worm of the nereid Platynereis dumerilii, comprising 11,402 mostly differentiated cells with distinct morphological properties (Vergara et al., 2021). We show that our method yields morphological descriptors -MorphoFeatures -that are in strong agreement with human perception of morphological similarity and quantitatively outperform manually defined features on cell classification and symmetric partner detection tasks. We further illustrate how our features can facilitate the detection of cell types by morphological means, via similarity-based clustering in the MorphoFeature vector space, sorting the cells into morphologically meaningful groups that show high correlation with genetically defined types such as muscle cells and neurons. Our pipeline also allows for the characterisation of rare cell types, such as enteric neurons and rhabdomeric photoreceptors, and detects distinct cell populations within the developing midgut. Finally, defining feature vectors that also represent the morphology of immediate neighbours, we group cells into tissues and also obtain larger groupings that represent entire organs. We show that such neighbourhood-based MorphoContextFeatures clustering reproduces manually annotated ganglionic nuclei in the annelid brain and represents a powerful tool to automatically and comprehensively detect the distinct tissues that belong to and make up the foregut of the nereid worm -including highly specialised and intricate structures such as the neurosecretory infracerebral gland (Baskin, 1974;Hofmann, 1976;Golding, 1970) and the axochord that has been likened to the chordate notochord (Lauri et al., 2014). We further show that such morphologically defined tissues and organs correlate with cell type and tissue-specific gene expression. Our work thus sets the stage for linking genetic identity and structure-function of cell types, tissues, and organs across an entire animal.

7The MorphoFeatures for the Platynereis dataset, as well as the code to generate and analyse them are available at https://github.com/kreshuklab/MorphoFeatures, (Zinchenko, 2023 copy archived at swh:1:rev:f13d505f68e0dc08bd5fed9121ee56e45b4bd6ac).

Unsupervised deep-learning extracts extensive morphological features

8Our pipeline has been designed to extract morphological descriptors of cells (MorphoFeatures) from EM data. It requires prior segmentation of all the cells and nuclei of interest. The pipeline utilises segmentation masks to extract single cells/nuclei and represents their morphology as a combination of three essential components: shape, coarse, and fine texture ( Figure 1A). We train neural networks to represent these components independently, using point clouds as input for shape, low-resolution raw data for coarse texture with sufficient context and small, high-resolution crops of raw data for fine texture. Separating these components ensures they are all represented in the final features and facilitates further interpretation. The features are combined to form one feature vector for each cell of the animal.

9A common way to train a neural network for extracting relevant features is to use some prior information about samples in the dataset as a source of supervision. For example, to extract morphological representations of cells, one could use a complementary task of predicting cell lines (Yao et al., 2019;Doan et al., 2020;Eulenberg et al., 2017), experimental conditions the cells are coming from Caicedo et al., 2018, or classification of proteins fluorescently labelled in the cells (Kobayashi et al., 2021). However, such metadata is mostly unavailable for EM volumes, and manual annotation might become infeasible with increasing data size. Moreover, exploratory studies are often aimed at discovering unusual morphology, new cell types, or tissues. In this case, defining supervision is not only difficult but might also bias the exploration towards the 'proxy' groups used for supervision. To enable immediate data exploration even for datasets where direct supervision is hard to define and the ground truth cannot easily be obtained, we developed a fully unsupervised training pipeline that is based on two complementary objectives ( Figure 1B and C). The first is an autoencoder reconstruction loss, where a network extracts a low-dimensional representation of each cell and then uses this representation to reconstruct back the original cell volume. This loss encourages the network to extract the most comprehensive description. The second objective is a contrastive loss that ensures the feature vectors extracted from two similarly looking cells (positive samples) are closer to each other than to feature vectors extracted from more dissimilar cells (negative samples). Since we do not know in advance which samples can be considered positive for our dataset, we are using slightly different views of the same cell, generated by applying realistic transformations to cell volumes (see Materials and methods). The combination of these two losses encourages the learned features to retain the maximal amount of information about the cells, while enforcing distances between feature vectors to reflect morphological similarity of cells. The pipeline was trained and applied on the cellular atlas of the marine annelid P. dumerilii (Vergara et al., 2021). It comprises a 3D SBEM volume of the whole animal that has sufficient resolution to Cell segmentation is used to mask the volume of a specific cell (and its nucleus) in the raw data. Neural networks are trained to represent shape, coarse, and fine texture from the cell volume (separately for cytoplasm and nuclei). The resulting features are combined in one MorphoFeatures vector that is used for the subsequent analysis. (B) Training procedure for the shape features. A contrastive loss is used to decrease the distance between the feature vectors of two augmented views of the same cell and increase the distance to another cell. (C) Training procedure for the coarse and fine texture features (here illustrated by coarse texture). Besides the contrastive loss, an autoencoder loss is used that drives the network to reconstruct the original cell from the feature vector. distinguish ultrastructural elements (organelles and inclusions, nuclear and cytoplasm texture, etc.) and an automated segmentation of 11,402 cells and nuclei ( Figure 1A). Additionally, whole-animal gene expression maps are available that cover many differentiation genes and transcription factors. Such a high number of morphologically and genetically diverse cells can make the initial exploratory analysis difficult. We designed MorphoFeatures to enable unbiased exploration of morphological variability in the animal on both cellular and tissue level; and indeed our training procedure yields 480 features that extensively describe each cell in terms of its cytoplasm and nucleus shape, coarse texture, and fine texture (80 features for each category (Pape et al., 2022) in Fiji (Schindelin et al., 2012).

MorphoFeatures allow for accurate morphological class prediction

10Good morphological features should distinguish visibly separate cell groups present in the data. To estimate the representation quality of our MorphoFeatures, we quantified how well they can be used to tell such groups apart. We took the morphological cell class labels available in the dataset, proofread, corrected, and expanded them. These labels include seven general classes of cells: neurons, epithelial cells, midgut cells, muscle cells, secretory cells, dark neurosecretory cells, and ciliary band cells ( Figure 2A) with ~60 annotated cells per class in the whole volume. It is worth noting that these cell classes were chosen based on visual morphological traits and do not necessarily represent genetically defined cell type families (Arendt et al., 2019). For example, while ciliary band cells are a small narrow group of morphologically homogeneous cells that likely constitute one cell type family, secretory cells were defined as cells with abundant organelles/inclusions in their cytoplasm that could indicate secretion, spanning a wider range of morphologies and, potentially, genetically defined cell types. We extracted MorphoFeatures by passing all the cells through the neural network trained as described above ( Figure 1A) and used them as an input to train a logistic regression classifier to predict the above-mentioned cell classes. This classifier has few parameters and can be trained even on the modest number of labels we have available. If any subset of the features strongly correlates with a given cell class, the model will show high performance. A classifier with MorphoFeatures achieved an accuracy of 96%, showing that the learned features are sufficient to distinguish broad morphological classes. To better understand remaining inaccuracies, we show the errors made by the classifier in Figure 2B and Figure 2-figure supplement 1A. This reveals, as expected, that while morphologically homogeneous classes can be easily separated, the classifier tends to confuse some secretory cells with other types (midgut and epithelial cells) that are also difficult to discern by eye and might well be mis-annotated. It also confuses the general neuron class with neurosecretory cells that represent a subclass of neurons.

11To illustrate large-scale performance of the broad cell type classification model, we show its predictions on the whole animal in Figure 2C and D and Figure 2-figure supplement 1B. These results demonstrate that MorphoFeatures are sufficiently expressive to enable training a generalisable model from a small number of labels, taking epithelial cells as a showcase: while the model was trained exclusively on the cells of the outer animal surface, it successfully predicted the cells outlining the gut opening and the chaetae cells as epithelial as well. Even more convincingly, the model predicted some cells in the midgut region as neurons, which after careful visual examination were indeed confirmed to be enteric neurons.

12To explore to which extent each of the morphology components (e.g. cell shape or fine nuclear texture) contributes to predicting the manually labelled cell classes, we ran a similar classification pipeline using these components separately ( Figure 2-figure supplement 2). The results show that, for example, cytoplasm texture is sufficient to tell some classes apart with high precision. However, both coarse and fine cytoplasm texture perform slightly worse on distinguishing neurosecretory cells, in which nuclei occupy almost the whole cell volume. Cell shape is satisfactory to characterise neurons and muscle cells but shows inferior performance on epithelial and secretory cells, which display a great variety of cell shapes. Surprisingly, nuclear fine texture features correctly distinguish, among other classes, muscle cells, suggesting that this class has characteristic chromatin texture.

13In Vergara et al., 2021, morphological classification of cells was performed based on manually defined features, including descriptors of shape (e.g. volume, sphericity, and major and minor axes), intensity (e.g. intensity mean, median and SD), and texture (Haralick features) extracted from the cell, nucleus, and chromatin segmentations, with 140 features in total. To compare these explicitly defined features with implicitly learned MorphoFeatures, we passed them through the same evaluation pipeline yielding a classifier which achieves the accuracy of 94%, in comparison to 96% achieved by MorphoFeatures. The classifier mostly made similar mistakes but performed worse on the classes of muscle and epithelial cells. Both sets of features demonstrate high accuracy on the broad morphological type classification task. For a more detailed comparison, we turn to a different task which allows us to implicitly, but quantitatively, evaluate how well the features group similar cells together.

14We use the metric introduced in Vergara et al., 2021 that is based on the fact that the animal is bilaterally symmetric, thus almost all the cells on one side of the animal will have a symmetric partner. The metric estimates how close a given cell is to its potential symmetric partner in the morphological feature space in comparison to all the other cells in the animal (see Materials and methods). According to this metric, our MorphoFeatures are 38% more precise in locating a symmetric partner than the ones from Vergara et al., 2021, showing the widely accepted superiority of neural network extracted features to explicitly defined ones.

MorphoFeatures uncover groups of morphologically similar cells

15Comprehensive analysis of morphological features should enable the grouping of cells with similar morphology, which may represent cell types. We investigated the grouping induced by Morpho-Features by projecting the features of all the animal cells onto 2D space using the dimensionality reduction technique UMAP (McInnes et al., 2018). To explore the quality of our representations, we repeatedly took a random cell from the animal and visualised its three closest neighbours ( Figure 3A). This shows that cells in close proximity in the feature space appear highly visually similar and might represent cell types at the morphological level. For example, a group of secretory cells in which the cytoplasm is filled with round electron-transparent vesicles (upper green panel) corresponds to the 'bright droplets' cells from Verasztó et al., 2020. Another group of secretory cells has an extensive endoplasmic reticulum (ER) surrounding the nucleus with a prominent nucleolus (lower green panel) and represents parapodial spinning gland cells (Verasztó et al., 2020). One can also see clear groups of flat developing midgut cells (brown panel), short muscles (red panel), ciliary band cells on the outer animal surface (yellow panel) as well as extended flat and short round epithelial cells (orange panels). Another interesting observation is that even though the neurite morphology is not taken into account, neurons show remarkable diversity based on soma morphology only (blue panels). Careful examination of a group of cells, initially labelled as neurons, that are located next to the epithelial cells on the UMAP projection (upper right blue panel) revealed that these cells are sensory cells that extend their processes to the epithelial surface.

16To explore the structure of the MorphoFeatures space, we performed hierarchical clustering of all cells. In the first clustering round, we split cells into 15 broad morphological groups ( Figure 3B). Cluster content could be revealed through available annotations and visualisation with the Platy-Browser (Pape et al., 2022; Figure 3B): Clusters 1-8 represent different groups of neurons; 9-11 epithelial cells; 12 and 13 are muscles; 14 midgut cells; while cluster 15 was further subclustered into secretory cells (subcluster 1) and ciliary band cells (subcluster 2). MorphoFeatures can thus guide the morphological exploration of a whole-animal volume, facilitating the discovery and annotation of morphologically coherent groups of cells ( Figure 3B). For example, the foregut epithelial cells are distinct from the epithelial cells of the outer animal surface and chaetae cells (clusters 9, 11, and 10, respectively). Separate groups are also formed by different types of neurons, for example, foregut neurons (cluster 4).

Morphological clusters have distinct gene expression profiles

17To further describe the morphological clusters, we took advantage of the whole-animal cellular gene expression atlas available for Platynereis (Vergara et al., 2021), containing more than 200 genes mapped onto the EM volume. We looked for genes that are highly expressed in a given cluster, while also being specific for this cluster -having low expression in the other cells of the animal.

18Many of our clusters show a clear genetic signature ( Figure 4A, Figure 4-figure supplement 1). Among the neurons, cluster 5 shows the most specific gene expression including the Transient receptor potential (Trp) channels pkd2, trpV4, and trpV5, and the bHLH transcription factor asci, which demarcate sensory cells of the palpal, antennal, and cirral ganglia (Vergara et al., 2021). Cluster 1 shows specific expression of the homeodomain transcription factors lhx6 and phox2 and an ap2 family member, while cluster 6 composed of dark neurosecretory cells shows specific expression of two neurosecretion markers, atrial natriuretic peptide receptor anpra and prohormone convertase phc2, identifying these as brain parts of the circular and apical nervous system, respectively (Vergara et al., 2021;Arendt, 2021). Cluster 8, another neural cluster, is enriched for the oxidative stress marker cytoglobin (globin-like; Song et al., 2020) and the bHLH transcription factor mitf. Subclustering revealed three subclusters, one of which represents rhabdomeric photoreceptors of the adult eye ( Figure 3B, subcluster 8.1) that specifically express mitf and globin-like. An average cell in this subcluster ( Figure 4B) shows abundant black inclusions. The second subcluster (8.2) contains pigment cells with black pigment granules. Cells in the third subcluster (8.3) are located in the midgut, with a smooth oval shape, neurite extensions and nuclei taking up the most cell volume ( Figure 4C and D) -in striking contrast to other midgut cells but resembling neurons, making it likely that these cells some clusters, the cells comprising the cluster are shown in the animal volume to visualise the cell type. For example, cluster 6 precisely picks out the dark neurosecretory cells, while cluster 14 corresponds to the midgut cells (see Text for more details). Scale bars: 10μm.

19The online version of this article includes the following figure supplement(s) for figure 3: represent enteric neurons previously postulated on the basis of serotonin staining (Brunet et al., 2016). Among the epidermal cells, the outer cluster 11 is enriched for protocadherin (pcdh15) and neurotrypsin (ntrps), whereas cluster 9 representing foregut epidermis shows high specificity for the bHLH transcription factor sim1 and the homeodomain factor pou3 (brn124, known to be expressed in stomodeal ectoderm in sea urchin; Cole and Arnone, 2009). For the muscles, the specific expression of striated muscle-specific myosin heavy chain mhcl4 in cluster 12 denotes the group of striated somatic muscles, while its absence in cluster 13 indicates that the foregut muscles have not yet switched to expressing striated markers (Brunet et al., 2016). Instead, the high and specific expression of the calexcitin-like sarcoplasmic calcium-binding protein Scp2 (calexcitin2; White et al., 2011), calmodulin, and of the Boule homologue Boll (boule-like) in cluster 13 suggests a calcium excitation and/or sequestration mechanism specific for foregut muscles. Finally, the cluster of midgut cells (cluster 14) specifically expresses the forkhead domain transcription factor foxA (for), a gut developmental marker (Boyle and Seaver, 2008) and TrpV-c, another Trp channel paralogue of the vanilloid subtype with presumed mechanosensory function.

20Beyond that, we noted considerable genetic heterogeneity in the midgut cluster. Finer clustering ( Figure 5) revealed one subcluster with strong expression of the smooth muscle markers non-muscle-mhc and mrlc2, and another expressing a chitinase related to chitotriosidase (nov2) and the zinc finger transcription factor Prdm16/mecom, known to maintain homeostasis in intestinal epithelia (Stine et al., 2019). Visualising the cells belonging to each subcluster and the specifically expressed genes in the PlatyBrowser ( Figure 5E) revealed distinct territories in the differentiating midgut, which we interpret as midgut smooth musculature and digestive epithelia. We also detected an enigmatic third cluster located outside of the midgut, in the animal parapodia, comprising cells that resemble midgut cells morphologically ( Figure 5D). For this subcluster, the current gene repertoire of the cellular expression atlas did not reveal any specifically expressed gene.

MorphoFeatures correspond to visually interpretable morphological properties

21Neural networks are often referred to as 'black boxes' to signify that it is not straightforward to trace learned features or decisions back to particular input properties. To examine whether it is possible to understand which properties of cells learned by our network distinguish the discovered morphological groups, we first identified MorphoFeatures that have high values specific to each cluster (Figure 6figure supplement 1). Then for a set of characteristic features, we visualised cells that correspond to the maximum and minimum value of the corresponding feature ( Figure 6). Visual inspection showed that many of them can be matched to visually comprehensible properties.

22For example, cytoplasm coarse texture feature 21 ( Figure 6, upper left), which distinguishes the outer epithelial cells (cluster 11), shows its minimal value in secretory cells, which contain multiple highly distinct types of texture, and its maximal value in the cells crowded with small vesicles and cisternae on the surface of the animal. The cluster of enteric neurons (cluster 8.3) strongly differs from other neurons by nuclear coarse texture feature 4 ( Figure 6, upper right), which contrasts nuclei with large amount of heterochromatin often attached to the nuclear lamina to nuclei with a high amount of euchromatin and prominent nucleoli. Cytoplasm fine texture feature 50 ( Figure 6, middle left), characteristic to the midgut cells (cluster 14), is the lowest in cells with a small stretch of homogeneous cytoplasm with mitochondria and has its peak in cells with abundant Golgi cisternae and mediumsized mitochondria. Rhabdomeric photoreceptors of the adult eye (cluster 8.1) display specific nuclear fine texture feature 7 ( Figure 6, middle right) that differentiates between nuclei with smooth and rather grainy texture. Cell shape feature 14 ( Figure 6, lower left) has its minimal value found in beakershaped cells with smooth surface and its maximal value in rather round cells with extremely rugged surface and is specific for ciliary band cells (cluster 15.2). Foregut muscles (cluster 13) can be described using nuclear shape feature 66 ( Figure 6, lower right), having one extreme in nuclei with a small compartment with a rough surface (as a result of a segmentation error) and the other extreme in elongated flat nuclei. Adding neighbour morphological information helps to identify tissues and organs

23Most cells do not function in isolation but rather form tissues, i.e., groups of structurally and functionally similar cells with interspersed extracellular matrix. We set out to systematically identify tissues with a new feature vector assigned to each cell that takes into account information about the morphology of neighbouring cells. For this, we combined the MorphoFeatures of a cell with the average Morpho-Features of its immediate neighbours, yielding a feature vector that represents the morphology of both the cell and its surrounding, which we refer to as MorphoContextFeatures. Applying the representation analysis described before, we find that proximity in MorphoContex-tFeature space no longer reflects morphological similarity only but rather identifies neighbouring groups of morphologically similar cells (whereby the neighbouring groups can be morphologically dissimilar). In other words, we now identify different tissues that together constitute organs composed of various tissues (Figure 7). For example, a separate assembly of groups of cells in the lower part of the UMAP projection represents the animal foregut subdivided into its constituting tissues comprising foregut neurons (lower blue panel), foregut muscles (lower beige panel), and foregut epithelium (left yellow-green panel). Next to this, we identify a group of muscles surrounding the foregut (left red panel). For the nervous system, adding neighbourhood information helps distinguishing cirral, palpal, and dorsal ganglia (three upper right panels, from left to right), as well as the ventral nerve cord and peripheral ganglia (two lower right panels). To benchmark the quality of this grouping, we clustered all the cells in the MorphoContextFeature space (see Materials and methods) and compared the neuron clusters to both manually segmented ganglionic nuclei and to the genetically defined neuronal clusters taking into account available gene expression in the cellular atlas (Vergara et al., 2021; Figure 8A and B). Notably, manual segmentation of brain tissues relied on visible tissue boundaries and thus has lower quality in the areas where such boundaries are not sufficiently distinct.

24In essence, all three ways of defining ganglia lead to very similar results ( Figure 8B), yet MorphoC-ontextFeature clustering appeared to be the most powerful. Gene clustering failed to distinguish the circumpalpal ganglion, defined both by manual segmentation and MorphoContextFeature clustering, due to the lack of distinct gene expression in the atlas. Manual segmentation failed to distinguish between the dorso-posterior and dorsal-anterior ganglionic nuclei due to the lack of distinct tissue boundaries. These are well defined by gene clustering and subdivided even further by MorphoCon-textFeature clustering. Unaware of the physical tissue boundaries, MorphoContextFeatures sometimes led to ambiguous assignment of cells neighbouring other tissues, especially cells with strongly different morphology. Such noisy assignment can be noticed, for example, in the neurons bordering muscle cells on the boundary of the cirral ganglia and in the centre of the brain.

25To further examine the contribution of incorporating cellular neighbourhood morphology, we visualise the discovered foregut tissues and ganglia on the MorphoFeatures representation (Figure 8figure supplement 1 and Figure 9-figure supplement 1). This shows that while some of the tissues, such as palpal ganglia or foregut epithelium, are composed of cells of one morphological type, others, e.g., circumpalpal ganglia or infracerebral gland, comprise cells with different morphology and could only be detected when taking into account cellular context as well.

Unbiased exploration of foregut tissues

26To further illustrate how MorphoContextFeatures can assist an unbiased exploration of an animal EM volume, we focused on the foregut. Subclustering whenever suitable ( Figure 9A; see Materials and methods), the resulting clusters revealed various foregut tissues including foregut epidermis, ganglia, inner musculature, and a prominent muscle surrounding the foregut. We also found a tissue of secretory neuron-like cells that surround the foregut like a collar ( Figure 9B and C, in green).

27of the genes shown to be differentially expressed in the two subclusters, plotted on the UMAP representation. (D) The location (upper panel) and an example cell (lower panel) of the subcluster located in the animal parapodia. Scale bars: upper panel -25μm, lower panel -5μm. (E) Cells belonging to the two cell types (left panels) and the genes differentiating them (centre and right panels) are visualised in the animal volume, with colour representing gene expression overlayed on the electron microscopy (EM) plane view. Scale bar: 10μm. Further inspection revealed that the latter structure is located underneath the brain neuropil and close to the neurosecretory endings of the neurosecretory plexus (Verasztó et al., 2020) and is bounded by thin layers of longitudinal muscle fibres on both the outer and the inner surface ( Figure 9-figure supplement 2A). The location of the structure indicated it might be the differentiating infracerebral gland -a neurosecretory gland located beneath the brain assumed to play a role in sensing blood glucose levels (Backfisch, 2013;Baskin, 1974;Hofmann, 1976;Golding, 1970). The organ is leaf-shaped and lays between the posterior pair of adult eyes (Figure 9- Figure 6. Visualisation of the learned features. For each feature, four cells with a minimal (blue) and four cells with a maximal (red) value of the feature are shown, see text for detailed analysis. Shown are cytoplasm coarse texture feature 21, nuclear coarse texture feature 4, cytoplasm fine texture feature 50, nuclear fine texture feature 7, cytoplasm shape feature 14, and nuclear shape feature 66. Scale bars: coarse texture -2μm, fine texture -1μm.

28The online version of this article includes the following figure supplement(s) for figure 6: supplement 2B) as also described in Backfisch, 2013 and borders a cavity likely to be a developing blood vessel (Figure 9-figure supplement 2C). In comparison to the foregut neurons that express sodium channel scn8aa, the infracerebral gland cells specifically express homeobox protein onecut/ hnf6 ( Figure 9D and E). We also noted that the tissue stains positive for EdU applied between 3 and 5 dpf, indicating that it is still proliferating. We then identified the prominent muscles surrounding the foregut as the anterior extension of the axochord (Lauri et al., 2014). Visualising the genes specifically expressed in these muscles, we noticed specific expression of the type I collagen gene col1a1, a marker for axochordal tissue, and of muscle junctional gene junctophilin1 ( Figure 9F). An anterior extension of the axochord around the foregut has been observed in several species and is described in Lauri et al., 2014;Brunet et al., 2016;Nielsen et al., 2018.

Discussion

29We presented an automated method of extracting comprehensive representations of cellular morphology from segmented whole-animal EM data. In stark contrast to the currently available methods, ours refrains both from specifying features explicitly and from predefining a concrete task that might skew the method towards extracting specific features: putting emphasis on some features may bias descriptions towards specific morphologies or cell types, hindering exploratory analysis. To obtain extensive generally useful representations, we rely on the latest progress in self-supervised deep learning and set only two criteria for the extracted features: (1) they have to be sufficiently detailed to allow reconstructing the original cell volume and (2) they have to bring visually similar cells in feature space closer to each other than dissimilar ones. We train a deep-learning pipeline optimised for these two conditions and show that it produces rich cellular representations, combining shape-, ultrastructure-, and texture-based features. More precisely, we show that the obtained representations (MorphoFeatures) capture fine morphological peculiarities and group together cells with similar visual appearance and localisation in the animal. Clustering of cells in the MorphoFeature space and taking advantage of an existing gene expression atlas with cellular resolution, we show that the obtained clusters represent units with differential and coherent gene expression.

30Both for morphological type and for tissue detection, we illustrate how MorphoFeatures can facilitate unbiased exploratory analysis aimed at detecting and characterising unusual phenotypes or unusual cell neighbourhoods. Moreover, we show quantitative superiority of MorphoFeatures over a broad range of manually defined features on the tasks of cell classification and symmetric partner detection. We also show that, despite being learned implicitly, MorphoFeatures still correspond to visually understandable properties and can often be interpreted. Finally, adding morphological information from the neighbouring cells (MorphoContextFeatures), we reveal the power of our approach to detect local groups of cells with similar morphology that represent tissues.

31Since our pipeline is based on the fast-evolving field of self-supervised deep learning, we expect it to further improve with its general advancement. For example, a promising direction are models, such as Grill et al., 2020, that only rely on positive samples and remove the need to define which cells belong to a different type. Besides MorphoFeatures, we also believe that MorphoContextFeatures, which incorporate neighbourhood information, will potentially benefit from state-of-the-art selfsupervised techniques such as contrastive-learning techniques on graphs (Hassani and Khasahmadi, 2020;Velickovic et al., 2019). Additionally, we expect hardware improvement, i.e., GPU RAM size, to allow training bigger models on larger texture patches of higher resolution that might further refine the quality of morphological representations. Another interesting direction enabled by the modularity of our pipeline is to integrate data from other modalities. Our features currently integrate shape and texture information of cells, but one could also envision enriching cellular descriptions by adding different types of data, e.g., transcriptomics, proteomics, or metabolomics, in a similar manner.

Versatility of the MorphoFeatures toolbox

32We envision our pipeline to enable, for the first time, fast systematic investigation of large EM volumes that involves consistent grouping and characterisation of morphological types, discovering particular phenotypes and neighbourhoods, as well as localising cells or tissues in an animal volume that are visually similar to cells or groups of cells of interest. Moreover, we expect MorphoFeatures to be useful for studies where several image volumes of the same species are acquired, be it another sample, a varying phenotype, or a different developmental stage. In such cases, training the pipeline on multiple volumes simultaneously to produce sample-independent features would result in morphological representations that can be used to map cells to their corresponding partners in another volume, enabling unbiased comparative analysis at scale. In addition, in case the other volumes are not segmented, one could use the fine texture part of MorphoFeatures to locate patches with phenotypic characteristic signature or cells with distinct ultrastructure (e.g. muscles and secretory cells). Using fine texture descriptors in such cases can also facilitate further segmentation since the segmentation of the previous volume can be used to define constraints of which textures can co-occur in the cells of the animal. However, given the high sensitivity of neural networks to intensity variations, it cord. Scale bars: 10μm. (C) Gene expression dot plot of the ganglia defined by MorphoContextFeature clustering.

33The size of the dots shows how much of a cluster expresses a gene; the colour shows how much of the expression of a gene is confined to a cluster (see Materials and methods). (D) Some of the genes shown to be differentially expressed in the ganglia defined by MorphoContextFeature clustering, plotted on the UMAP representation.

34The online version of this article includes the following figure supplement(s) for figure 8: will be essential to avoid non-biological systematic change in the visual appearance of cells such as intensity shifts, both within and between the EM volumes.

35The presented pipeline can also be adjusted for other types of data. For example, since our analysis revealed a high variability in neuronal soma morphologies, it appears reasonable to also apply the pipeline to brain EM volumes, where MorphoFeatures could supplement neuron skeleton features for more precise neuronal morphology description. We also expect the approach to contribute to the analysis of cells in other volumetric modalities, such as X-ray holographic nano-tomography (Kuan et al., 2020). For light microscopy with membrane staining, we expect the shape part of the Morpho-Features pipeline to be directly applicable and a useful addition to existing analysis tools. Generally, the versatility of the pipeline is enhanced by its modularity that makes it possible to adapt different parts (e.g. cell shape or nucleus fine texture) to datasets where not all the morphological components are desired or can be extracted.

Identification of cell types and cell type families with MorphoFeatures

36Any attempt to define cell types morphologically has so far been hampered by the selection of relevant properties. What are the morphological features that are best suited for recognising cell types? Regarding neurons, the shapes of dendrites and axons, soma size, and spine density have been measured, in combination with physiological properties including resting potential, biophysical properties, and firing rate (Zeng and Sanes, 2017). Volume EM has recently allowed considerable expansion of morphometric parameters, including various shape, intensity, and texture features (Vergara et al., 2021). Using these numerous parameters, it is possible to discern general categories such as neurons, muscle, or midgut cells; yet they do not provide further resolution within these groups. Comparing the MorphoFeatures representations to the predefined features (Vergara et al., 2021) hints at supreme resolution power that appears to distinguish morphological groupings down to the cell type level (Figure 4-figure supplement 2). For example, the subclusters of rhabdomeric photoreceptors of the adult eye and enteric neurons can not be identified in the explicit features representation. Furthermore, the cluster of foregut muscles revealed by the MorphoFeatures appears to be split, with some cells being found closer to striated muscles and some residing between the groups of neurons and dark neurosecretory cells.

37Most importantly, the cell clusters identified in MorphoFeature space appear to come closest to genetically defined cell types, as demonstrated here, among others, for different types of mechanosensory cells or cell types of the apical nervous system. Interestingly, the MorphoFeatures also unravel morphological cell types without a genetic match in the cell type atlas (such as the enteric neurons, see above). This is most likely due to the yet limited coverage of the atlas and expected to improve with the continuous addition of genes to the atlas. In particular, the integration of other multimodal omics datasets such as single cell transcriptomics data will be highly rewarding to improve the match between morphological and molecularly defined cell types, which is the ultimate aim of cell type characterisation and categorisation (Zeng and Sanes, 2017).

Towards an unbiased whole-body identification of tissues and organs

38The current revolution in the generation of giant volume EM datasets including representations of entire bodies calls for new strategies in the automated processing and comparison of such datasets. This not only involves segmentation and characterisation at the cellular level but also requires the automated identification of discernable structures at the level of tissues and organs. So far, the recognition of tissues in larger volumes was achieved by manual segmentation. We now present a powerful new algorithm to recognise tissues and organs via their co-clustering in the MorphoContextFeature expression dot plot of the foregut region clustering. The size of the dots shows how much of a cluster expresses a gene; the colour shows how much of the expression of a gene is confined to a cluster (see Materials and methods). The genes mentioned in the text are enboxed. (F) The genes specific to the axocord muscles, visualised on the animal volume. Scale bars: 10μm.

39The online version of this article includes the following figure supplement(s) for figure 9: space, which takes into account similarities between cell neighbourhoods. Using this algorithm, we reproduce and partially outperform tissue recognition via manual segmentation -as exemplified for the ganglionic nuclei of the nereid brain. Beyond that, we present a comprehensive account of foregut tissues, without prior manual segmentation. This analysis reveals a rich collection of tissues including an anterior extension of the axochord surrounding the foregut (Lauri et al., 2014) and the infracerebral gland (Baskin, 1974;Golding, 1970), an adenohypophysis-like neurosecretory tissue that we identify as anterior bilateral extensions of the foregut roof.

40While the manual segmentation of tissues mostly relies on the detection of tissue boundaries, our automated tissue detection equally processes the morphological similarities of its constituting cells. This enables tissue separation even in cases where morphological boundaries appear to be absent, as is the case for the anterior and posterior dorsal ganglionic nuclei, which are lacking a clear boundary but are composed of morphologically different cell types that are also genetically distinct (Vergara et al., 2021).

Conclusion

41The revolution in multi-omics techniques and volume EM has unleashed enormous potential in generating multimodal atlases for tissues as well as entire organs and animals. The main unit of reference in these atlases is the cell type, which has been defined, and is manifest, both molecularly and morphologically. Our work now provides a versatile new tool to recognise cell types in an automated, unbiased, and comprehensive manner solely based on ultrastructure and shape. For the first time, the MorphoFeatures will allow us to compare and identify corresponding cell types in datasets of the same species, but also between species, on purely morphological grounds.

42Furthermore, the MorphoContextFeatures automatically recognise tissues and organs across entire bodies, opening up new perspectives in comparative anatomy. Without previous knowledge, we can obtain the full complement of tissues and organs for a given specimen and quantitatively compare them to those of other specimens of the same or other species. In combination with cell type-, tissue-, and organ-specific expression data, this will enable us to identify corresponding traits in an unbiased manner and with unprecedented accuracy.

Data and preprocessing Data

43We used the dataset of the marine annelid P. dumerilii at late nectochaete stage (6 dpf) from Vergara et al., 2021. The dataset comprised an SBEM volume of the complete worm in 10 × 10 × 25 nm resolution, 3D cell and nucleus segmentation masks as well as Whole Mount In-Situ Hybridisation (WMISH) gene expression maps. The segmentation contains 11,402 cells with nuclei that belong to multiple genetically and morphologically distinct cell types. It is important to note that for neurons only somata were segmented since the imaging resolution did not allow for neurite tracing. The gene expression maps cover mainly differentiation genes and transcription factors, which were registered onto the EM volume, exploiting high stereotypy of the Platynereis at this stage of development. Gene expression values were also assigned to the EM segmented cells. The maps contain 201 genes and 4 EdU proliferation stainings. We refer to Vergara et al., 2021 for further details. Since the intensity correction algorithm that was used in the EM volume performed unreliably in regions close to the boundaries of the volume in the z-axis, we excluded all cells located within the region of uncertain intensity assignment quality. These regions correspond to parts of the animal's head and the pygidium.

Preprocessing

44The EM dataset is used to extract the three morphological components separately for cytoplasm and nuclei as follows. Due to the limitations of the GPU memory, for the coarse texture, a central crop is taken from a downsampled version of the data (80 × 80 × 100 nm). The centre of mass of the nucleus is determined, and a bounding box of size 144 × 144 ×144 pixels (cytoplasm) or 104 × 104 × 104 (nuclei) is taken around it. During prediction, the bounding box is increased to 320 × 320 × 320 (cytoplasm) and 160 × 160 × 160 (nuclei) to fit more information. Fine texture patches have a higher resolution (20 × 20 × 25 nm) and are taken separately from cytoplasm and nucleus. For this, the bounding box surrounding cytoplasm or nucleus is split into cubes of 32 × 32 × 32 pixels, and only those cubes are considered which are less than 50% empty. For both coarse and fine texture, the data is normalised to the range of [0, 1], and for cytoplasm crops, the nuclei are masked out and vice versa.

45In order to obtain point clouds and normals of the membrane surfaces, we first converted the segmented 3D voxel volumes into triangular meshes. More specifically, we first applied the marching cubes algorithm Lorensen and Cline, 1987;van der Walt et al., 2014 followed by Laplacian smoothing (Schroeder et al., 1998) to obtain smooth triangular surface meshes. These meshes were then simplified and made watertight using Stutz and Geiger, 2020;Cignoni et al., 2008. Having obtained smooth triangular meshes enables us to compute consistent normals and to apply complex deformations to the underlying surface. During training and inference, the meshes and their surface normals are sampled uniformly to be then processed by the neural network.

Unsupervised deep-learning pipeline

46This section describes our proposed algorithm in more detail. The training and prediction pipeline is implemented in Pytorch (Paszke et al., 2019). On a high level, our model consists of six encoder networks which leverage graph convolutional as well as regular convolutional layers in order to learn shape and texture aspects of a cell's morphology. We are using self-supervised learning in combination with stochastic gradient descent in order to obtain good network parameters. The objective that is optimised is a weighted sum of the NT-Xent loss and the mean squared error and can be interpreted as an unbiased proxy task. We will detail and elaborate on these aspects in the following sections.

Neural network model

47The proposed network, as depicted in (Figure 1A), contains six encoders which are encoding shape, coarse, and fine-grained texture of cells and nuclei.

48The shape encoder takes as input a set of points in the form of 3D Euclidean coordinates as well as the corresponding normals (see Data and preprocessing) and outputs an N-dimensional shape feature vector. The network itself is a DeepGCN model (Li et al., 2019), which is a deep neural network for processing unstructured sets such as point clouds. Conceptually, it consists of three building blocks. In the first block, k-nearest neighbour graphs are built dynamically in order to apply graph convolutions. This can be interpreted as pointwise passing and local aggregation of geometric information which is repeated multiple times. In the second block, the pointwise aggregated geometric information is fused by passing it through a convolutional layer followed by a max pooling operation that condenses the information into a high-dimensional latent vector. Finally, the obtained latent vector is passed through a multilayer perceptron to obtain the shape component of the overall feature vector.

49The encoding of fine texture details and coarser contextual information is done using the encoder of a U-Net (Ronneberger et al., 2015). The fully convolutional network reduces spatial information gradually by employing three blocks that consist of 3D convolutional layers with ELU activations (Clevert et al., 2015) separated by 3DMaxPooling layers. The number of feature maps starts with 64, increases twofold in each block, and afterwards gets reduced to 80 by an additional convolutional layer followed by an ELU activation. In the end, a global average pooling operation is applied to reduce feature dimensionality from 3D to 2D. To ensure that empty regions of the data are not affecting the final feature vector, they are excluded for this final pooling.

Training

50In order to find suitable representations, we leverage self-supervised contrastive learning (CL; Chen et al., 2020;Hadsell et al., 2006). The idea is to create a representation space in which morphologically similar cells are embedded close to each other, while dissimilar ones are embedded far apart. For learning representations of shape, we follow a purely contrastive approach, whereas for texture representations, we combine the CL objective with an autoencoder reconstruction loss. Both are described in more detail below.

51The training procedure for CL is the same for shape and texture representations. First, we randomly sample a mini batch of cells or nuclei. Two augmented views are then created for each sample in the batch (see Data augmentations) and concatenated to form an augmented batch of twice the size. The augmented batch is passed through the neural network encoder to compute representations. Those representations that share the same underlying sample are considered as positive pairs, whereas the others are considered as negative pairs. The NT-Xent loss is then used to score the representations based on their similarity and, therefore, encourages the network to embed positive pairs closer to each other than negative pairs. For learning shape representations, we first augmented all cell and nucleus meshes using biharmonic deformation fields and as-rigid-as-possible transformations in a preprocessing step (see Data augmentation). More specifically, we computed 10 random views for each membrane surface. The augmented meshes are then used for training, i.e., we compute surface normals and sample 1024 points and their corresponding normals which form the inputs of the shape encoders. In each training iteration, we sampled 48 cells/nuclei, which resulted in a batch size of 96. Adam (Kingma and Ba, 2014) with a learning rate of 0.0002 and a weight decay of 0.0004 was used to update the network parameters. The hyperparameters were obtained by a random search.

52In order to learn representations of texture, we combine the NT-Xent loss with an autoencoder reconstruction objective. The latent representations, taken before the dimensionality reduction step of global average pooling, are further processed by a symmetric decoder part of the UNet network with only one block, which aims to reconstruct the network inputs. The reconstructions are then compared to the original inputs and scored by a mean squared error loss. Additionally, an L2-Norm loss was applied to flattened bottleneck features to restrict the range of possible values. The final loss is thus a weighted sum of the NT-Xent, the mean squared error loss, and the L2-Norm loss. The batch size was set to 12 and 16 for cell and nuclei coarse texture and to 32 for fine texture. For training, we used Adam (Kingma and Ba, 2014) as optimizer with a learning rate of 0.0001 and a weight decay of 0.00005. The model was evaluated every 100 iterations, and the best result was saved with a patience of 0.95. The learning rate was reduced by 0.98 whenever the validation score did not show improvement with a patience of 0.95.

Data augmentation

53A key component for successful contrastive representation learning are suitable data augmentations. In our context, applying augmentations to a cell can be interpreted as creating morphological variations of a cell. By creating positive and negative pairs (cf. previous section), the network learns to distinguish true variations from noise and non-essential ones. It is therefore important to find a suitable set of transformations that distort the right features of a cell and do not change its morphological identity.

54As augmentations for shape, we leveraged biharmonic and as-rigid-as-possible transformations (Botsch and Kobbelt, 2004;Sorkine andAlexa, 2007, Jacobson et al., 2018) as they deform cellular and nuclear membranes in a way that retains most characteristic geometric features of the original surface. In order to compute these deformations, we sample so-called handle regions on the membrane surface. These regions are translated in a random, normal, or negative normal direction. The deformation constraint is then propagated to the rest of the surface either via a biharmonic deformation field or an as-rigid-as-possible deformation. We combine these deformations with random anisotropic scaling, rotations, and/or symmetry transformations.

55To create positive samples for the contrastive training of texture, we used random flips and rotations and elastic transformations of the data.

Inference

56In order to compute the MorphoFeatures representation for the whole animal, we processed each cell's cellular and nuclear shape and texture, as described in previous sections, with our trained networks. For the fine texture patches to get one feature vector per cell, the feature vectors of all the patches from a cell were averaged. Each cell is represented by a 480-dimensional vector that consists of a nuclear and cellular part. Each of these parts consists of a shape, coarse, and fine-grained texture 80-dimensional feature vector. This vector size was found empirically using the bilateral distance as a metric. Vectors of bigger size showed similar performance, but contained more redundant features.

Quantitative feature evaluation

57In this section, we describe our feature evaluation experiments in more detail. In order to assess the quality of MorphoFeatures quantitatively, we conducted cell-type prediction and bilateral pair analysis experiments. We use the same set of explicit features that were used in Vergara et al., 2021 for analysing cellular morphology as a baseline for comparisons.

Explicit feature baseline

58The explicitly defined representation includes shape features (volume in microns, extent, equivariant diameter, major and minor axes, surface area, sphericity, and max radius), intensity features (different quantiles of intensity mean, median, and SD), and Haralick texture features. These features were calculated, whenever appropriate, for cell cytoplasm, nucleus, and chromatin segmentation. The calculated features were taken from Vergara et al., 2021: https://github.com/mobie/platybrowser-project/blob/ main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology.tsv for cellular segmentation and from https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-nuclei/morphology.tsv for nucleus and chromatin segmentation. The UMAP of these features was taken from https://github.com/mobie/platybrowser-project/blob/main/data/1. 0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology_umap.tsv.

Classification of visibly distinct groups of cells

59In order to verify that MorphoFeatures can distinguish visibly different groups of cells, we evaluated the prediction accuracy of a logistic regression model that was trained on a small dataset of 390 annotated cells taken from Vergara et al., 2021 (Figure 2A). The original annotation contained 571 neurons, 141 epithelial cells, 55 midgut cells, 53 muscle cells, 51 secretory cells, 41 dark cells, and 25 ciliated cells. We first corrected the assignments deemed incorrect by the annotators with expertise in Platynereis cell types. Then for the classes that contained less than 60 cells, we manually annotated more cells. From bigger classes, we selected 60 cells, selecting the most morphologically diverse ones when possible. For ciliated cells, we were only able to locate 30 cells in the whole animal.

60First, we computed the MorphoFeatures representation for each cell in the animal (excluding cells with severe segmentation errors) and standardised features across the whole dataset. We then trained and validated a logistic regression model using a stratified k-folds cross validator with fivefolds. We used the implementations of logistic regression, stratified k-fold from Scikit-learn (Pedregosa et al., 2011) with the following arguments: C=1, solver = 'lbfgs'. To prevent potential overfitting due to the high number of features, we used feature agglomeration (Pedregosa et al., 2011;n_clusters = 100) to reduce the number of similar features.

Bilateral pair analysis

61The criterion of classifying distinct groups of cells in the previous section can be seen as a coarse and global way of evaluating MorphoFeatures. In this section, we describe how we used the animal's bilateral symmetry to have a more fine-grained measure for quantitatively evaluating nuanced morphological differences. The measure, which we will refer to as bilateral distance, was introduced in Vergara et al., 2021 and leverages the fact that most cells in the animal have a symmetric partner cell on the other side of the mediolateral axis. The bilateral distance is computed in the following way: first, we determine for each cell c a group of N potential partner cells {c 1 , , c N } on the opposite side. We then compute a ranking based on the Euclidean distances ∥c − c∥ in feature space between cell c and all other cells c ̸ = c . Since c 's symmetric partner has the same morphology, up to natural variability, it should be among the closest cells in the ranking. We then determine the highest ranked partner cell as rank(argmin n∈{1,...,N} ∥c − cn∥) . In doing this for all cells, we create a list containing the ranking positions of cells to their symmetric partner. The bilateral distance is then defined as the median of this list and can be interpreted as a measure of how close two morphologically very similar cells are on average in feature space.

Adding neighbour morphological information

62This section describes how neighbourhood information was incorporated into MorphoFeatures in order to obtain MorphoContextFeatures. First, we built a region adjacency graph from the cell segmentation masks using scikit-image (van der Walt et al., 2014). The obtained graph reflects the animal's cellular connectivity, i.e., cells are represented by nodes in the graph, and nodes are connected by an edge if the corresponding cells are neighbours. We then assign node attributes by mapping the MorphoFeatures representation of a cell to the corresponding node. Neighbourhood features are then obtained by computing the mean over a node's MorphoFeatures vector and the MorphoFeatures vectors of its surrounding neighbours. Finally, a cell's neighbourhood features are concatenated with the cell's MorphoFeatures to obtain the MorphoContextFeatures representation.

63We benchmarked multiple methods for aggregating feature vectors of neighbouring cells, including taking the mean, the median, and approaches based on graph neural networks. Among these methods, taking the mean showed to be the best tradeoff between performance and simplicity. Compared to taking the median, the mean features showed to give a higher accuracy on predicting morphotypes and have a lower bilateral distance. The features extracted by graph neural networks exhibited unstable behaviour, both in predictiveness of morphotypes as well as bilateral distance.

Feature analysis UMAP representation analysis

64Visualisation was done using the UMAP package (McInnes et al., 2018) with the following parameters: Euclidean metric, 15 neighbours, and 0 minimal distance. Cell metadata, such as annotated types, animal regions, or gene expression, was plotted on the resulting UMAP.

Clustering

65Cell clustering was done according to the following procedure. First, the features were standardised to zero mean and unit variance. Then, following Dubourg-Felonneau et al., 2021, a weighted k-neighbour graph was constructed from MorphoFeatures representations of all the animal cells using the UMAP algorithm (McInnes et al., 2018) with the following arguments: n_neighbours = 20, metric='Euclidean', and min_dist = 0. Afterwards the Leiden algorithm (Traag et al., 2019) for community detection was used to partition the resulting graph, using the CPMVertexPartition method and a resolution parameter of 0.004. For more fine-grained clustering, the resolution was increased to 0.1 to split apart secretory and ciliary band cells, 0.2 to split photoreceptors and enteric neurons, 0.07 to split the midgut cluster, 0.005 for muscle neighbourhood cluster (n_neighbours for the UMAP clustering was adjusted to 10), and 0.01 for splitting foregut neurons and epithelial cells.

66One of the clusters was discarded since visual examination showed it contained only cells with split segmentation errors that 'cut' through the nucleus area along one of the axes (examples shown in Figure 3-figure supplement 1). Other types of segmentation errors in the dataset mostly did not influence the clustering quality for multiple reasons. First, most errors are rather randomly distributed and not consistent, meaning the size of falsely attached fragments is highly variable, and the location of segmentation splits is not consistent. Secondly, many of the errors are cell type specific. For example, midgut cells often got merged with midgut lumen, (Figure 3-figure supplement 2, dark green) and muscle cells often experienced splits or merges of other muscle pieces (Figure 3-figure supplement 2, dark and light orange). Small merges that are not cell type specific (Figure 3-figure supplement 2, light green) also minimally affected the assignment. However, substantial merges could lead to a cell being grouped with a different cell type, for example, a neuron that got merged with a piece of epithelial cell bigger than the neuron size ( Figure 3-figure supplement 2, yellowgreen) got grouped together with epithelial cells, not neurons.

67To visualise average shape and texture of a cluster (4B,C), a median feature vector was computed across the cluster, and the cell with the feature vector closest to the median one was taken as the average cell.

Gene expression analysis

68To produce the cluster gene expression 'dot plots' (Figures 4A, 5B, 8C and 9E), the gene expression values for each cell were taken from Vergara et al., 2021 at https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/genes.tsv. Similar to Vergara et al., 2021, for each cluster and for each gene, we calculated three values: (A) the mean expression in the cluster, (B) the fraction of the total animal/region expression within this cluster (the sum of expression in this cluster divided by the sum of the expression in the whole animal or the selected region), and (C) the specificity defined as C = 2AB/(A + B) . Intuitively, A indicates how much of the cells in a given cluster express a given gene, B shows how selective this gene for this cluster is, and C is a harmonic mean of the two values. To create a dot plot, only the genes with C value above 0.15 were used. For the neuron clusters 1, 3, and 5 ( Figure 4A), the threshold was increased to 0.2 due to a high number of specifically expressed genes available. For the midgut clusters ( Figure 5) to show only the genes differing between the two clusters, the genes were removed, where the specificity was above 0.15 in both clusters but differed by less than 0.4. The size of the dots in the plots reflects A , and the colour corresponds to B . The cluster with the most gene expression was determined, and the remaining clusters were sorted by their similarity to it. To illustrate some of the genes showing differential expression in these groups ( Figures 5, 8 and 9), the corresponding regions of the UMAP representation were cut out, and these genes were plotted on top.

Feature specificity analysis

69The feature specificity 'dot plots' were generated as follows. The MorphoFeatures of all cells were processed by first clipping the values below -2 and above +2 (less than 5% of values affected) and standardised to the range of [0, 1]. Then three values A , B , and C were calculated similarly to gene expression dot plots. However, since smaller clusters would have smaller sum of any feature, we additionally normalised the value B by diving it by the relative cluster size. To create a dot plot, only the features with C value above 1 were used.

70To illustrate some features specific to clusters ( Figure 6-figure supplement 1), we first selected a set of features from the dot plot with high specificity in a given cluster and low specificity in other clusters. We then showed their extremes with cells that have the respective minimal/maximal value of this feature ( Figure 6). The cells with merge errors of more than half of a cell size were ignored. In order to visualise the 3D cells and nuclei, we selected a 2D view that we presume shows the shape or texture feature common between all four selected cells with minimal or maximal value of the feature.

71Visualising the extremes of various features from the dot plot, we found most features (80-90%) to be relatively easy to interpret. More specifically, 82% shape features, 80% fine texture features, and 90% coarse texture features could be visually mapped to explainable properties in less than 2 min of observing the data. However, when selecting a random subset (10-20 random features) from each morphological component, the number of clearly interpretable features was lower, 65% for fine, 70% for coarse texture, and 45% for shape features.

Ganglionic nuclei

72To compare ganglionic nuclei (Figure 8), we used manually segmented regions from https://github. com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/ ganglia_ids.tsv and https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/ sbem-6dpf-1-whole-segmented-cells/regions.tsv and gene clusters from https://github.com/mobie/ platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/gene_clusters.tsv (Vergara et al., 2021).

Data visualisation

73We used matplotlib (Hunter, 2007) and seaborn (Waskom, 2021) for plotting the data, MoBIE (Pape et al., 2022) for visualising cells in the EM volume, and vedo (Musy et al., 2022) for visualising meshed cells and tissues. The funders had no role in study design, data collection and interpretation, or the decision to submit the work for publication.

Introduction

74Development of multicellular organisms progressively gives rise to a variety of cell types, with differential gene expression resulting in different cellular structures that enable diverse cellular functions. Structures and functions together represent the phenotype of an organism. The characterisation of cell types is important to understand how organisms are built and function in general (Arendt, 2008). Recent advances in single-cell sequencing have allowed the monitoring of differential gene expression in the cell types that make up the tissues and organs of entire multicellular organisms and led to the recognition of distinct regulatory programmes driving the expression of unique sets of cell type-specific effector genes (Hobert and Kratsios, 2019;Sebé-Pedrós et al., 2018a;Sebé-Pedrós et al., 2018b;Musser et al., 2021;Fincher et al., 2018;Siebert et al., 2019). These distinct genetic programmes make the identity and thus define cell types Tanay and Sebé-Pedrós, 2021). The genetic individuation of cell types then translates into phenotypic differences between cells, and one of the most intriguing questions is to determine this causation for each cell type. Only then will we understand their structural and functional peculiarities and intricacies and learn how evolutionary cell type diversification has sustained organismal morphology and physiology. As a prerequisite towards this aim, we need a comprehensive monitoring and comparison of cellular phenotypes across the entire multicellular body, which can then be linked to the genetically defined cell types.

75Recent efforts have focused on large-scale high-resolution imaging to capture the morphological uniqueness of cell types. For the first time, the rapid progress in volume EM allows this for increasingly large samples, including organs and entire smaller animals, with nanometer resolution Vergara et al., 2021;Zheng et al., 2018;Scheffer et al., 2020;Cook et al., 2019;Verasztó et al., 2020). Supported by automated cell segmentation pipelines (Heinrich et al., 2021;Macrina et al., 2021;Pape et al., 2017;Müller et al., 2021), such datasets allow characterisation and comparison of cellular morphologies, including membrane-bound and membraneless organelles and inclusions, at an unprecedented level of detail for thousands of cells simultaneously (Turner et al., 2022;Vergara et al., 2021). A notable challenge of such large-scale studies is the analysis of massive amounts of imaging data that can no longer be inspected manually. The latest tools for visual exploration of multi-terabyte 3D data allow for seamless browsing through the regions of interest (Pietzsch et al., 2015;Maitin-Shepard et al., 2021), given such regions are specified and contain a limited number of cells. However, if the goal is to characterise and/or compare morphologies of most or all cells in the dataset, one has to be able to automatically assign each cell an unbiased comprehensive morphological description -a feature vector with values representing the morphological properties of the cell in the most parsimonious manner.

76The need for automation and quantitative evaluation has triggered the design of complex engineered features that capture specific cell characteristics (Barad et al., 2022). However, such features often have to be manually chosen and mostly provide only a limited, targeted view of the overall morphology. To alleviate this problem, intricate modelling pipelines for cellular morphology quantification have been developed (Ruan et al., 2020;Driscoll et al., 2019;Phillip et al., 2021); still, these are often data-and task-specific. For unbiased monitoring and comparison of cellular morphologies, broadly applicable automated pipelines are missing. They should, in addition, be capable of extracting comprehensive representations that are not biased by manual feature selection, the end task, or the type of data used. We expect that developing such techniques will not only speed up the process of scientific discovery in big volume imaging datasets but also facilitate detecting unusual and underrepresented morphologies.

77In the last decade, artificial neural networks have been shown to exceed manually engineered pipelines in extracting comprehensive descriptors for various types of data and to be particularly suited for the extraction of visual features (Krizhevsky et al., 2012;Falk et al., 2019;Simonyan and Zisserman, 2014;Girshick et al., 2014). Moreover, the rise of so-called self-supervised training methods has removed the necessity for generating massive amounts of manual annotations previously needed to train a network. Besides the obvious advantage of being less labour-intensive, selfsupervised methods do not optimise features for a specific end-task but instead produce descriptors that have been shown to be useful in a variety of downstream tasks, such as image classification, segmentation, and object detection (He et al., 2020;Van den Oord et al., 2018;Tian et al., 2020). Such methods have already shown to be successful for phenotyping cells in image-based profiling (Lu et al., 2019;Lafarge et al., 2019) and for describing local morphology of patches or subcompartments within neural cells in 3D electron microscopy (EM) of brain volumes Schubert et al., 2019). Building on the latest achievements, we aim to expand the feature extraction methods to automated characterisation of cellular morphology at the whole animal level.

78Here, we present the first framework for the fully unsupervised characterisation of cellular shapes and ultrastructures in a whole-body dataset for an entire animal. We apply this new tool to the fully segmented serial block-face EM (SBEM) volume of the 6 days post fertilisation young worm of the nereid Platynereis dumerilii, comprising 11,402 mostly differentiated cells with distinct morphological properties (Vergara et al., 2021). We show that our method yields morphological descriptors -MorphoFeatures -that are in strong agreement with human perception of morphological similarity and quantitatively outperform manually defined features on cell classification and symmetric partner detection tasks. We further illustrate how our features can facilitate the detection of cell types by morphological means, via similarity-based clustering in the MorphoFeature vector space, sorting the cells into morphologically meaningful groups that show high correlation with genetically defined types such as muscle cells and neurons. Our pipeline also allows for the characterisation of rare cell types, such as enteric neurons and rhabdomeric photoreceptors, and detects distinct cell populations within the developing midgut. Finally, defining feature vectors that also represent the morphology of immediate neighbours, we group cells into tissues and also obtain larger groupings that represent entire organs. We show that such neighbourhood-based MorphoContextFeatures clustering reproduces manually annotated ganglionic nuclei in the annelid brain and represents a powerful tool to automatically and comprehensively detect the distinct tissues that belong to and make up the foregut of the nereid worm -including highly specialised and intricate structures such as the neurosecretory infracerebral gland (Baskin, 1974;Hofmann, 1976;Golding, 1970) and the axochord that has been likened to the chordate notochord (Lauri et al., 2014). We further show that such morphologically defined tissues and organs correlate with cell type and tissue-specific gene expression. Our work thus sets the stage for linking genetic identity and structure-function of cell types, tissues, and organs across an entire animal.

79The MorphoFeatures for the Platynereis dataset, as well as the code to generate and analyse them are available at https://github.com/kreshuklab/MorphoFeatures, (Zinchenko, 2023 copy archived at swh:1:rev:f13d505f68e0dc08bd5fed9121ee56e45b4bd6ac).

Unsupervised deep-learning extracts extensive morphological features

80Our pipeline has been designed to extract morphological descriptors of cells (MorphoFeatures) from EM data. It requires prior segmentation of all the cells and nuclei of interest. The pipeline utilises segmentation masks to extract single cells/nuclei and represents their morphology as a combination of three essential components: shape, coarse, and fine texture ( Figure 1A). We train neural networks to represent these components independently, using point clouds as input for shape, low-resolution raw data for coarse texture with sufficient context and small, high-resolution crops of raw data for fine texture. Separating these components ensures they are all represented in the final features and facilitates further interpretation. The features are combined to form one feature vector for each cell of the animal.

81A common way to train a neural network for extracting relevant features is to use some prior information about samples in the dataset as a source of supervision. For example, to extract morphological representations of cells, one could use a complementary task of predicting cell lines (Yao et al., 2019;Doan et al., 2020;Eulenberg et al., 2017), experimental conditions the cells are coming from Caicedo et al., 2018, or classification of proteins fluorescently labelled in the cells (Kobayashi et al., 2021). However, such metadata is mostly unavailable for EM volumes, and manual annotation might become infeasible with increasing data size. Moreover, exploratory studies are often aimed at discovering unusual morphology, new cell types, or tissues. In this case, defining supervision is not only difficult but might also bias the exploration towards the 'proxy' groups used for supervision. To enable immediate data exploration even for datasets where direct supervision is hard to define and the ground truth cannot easily be obtained, we developed a fully unsupervised training pipeline that is based on two complementary objectives ( Figure 1B and C). The first is an autoencoder reconstruction loss, where a network extracts a low-dimensional representation of each cell and then uses this representation to reconstruct back the original cell volume. This loss encourages the network to extract the most comprehensive description. The second objective is a contrastive loss that ensures the feature vectors extracted from two similarly looking cells (positive samples) are closer to each other than to feature vectors extracted from more dissimilar cells (negative samples). Since we do not know in advance which samples can be considered positive for our dataset, we are using slightly different views of the same cell, generated by applying realistic transformations to cell volumes (see Materials and methods). The combination of these two losses encourages the learned features to retain the maximal amount of information about the cells, while enforcing distances between feature vectors to reflect morphological similarity of cells. The pipeline was trained and applied on the cellular atlas of the marine annelid P. dumerilii (Vergara et al., 2021). It comprises a 3D SBEM volume of the whole animal that has sufficient resolution to Cell segmentation is used to mask the volume of a specific cell (and its nucleus) in the raw data. Neural networks are trained to represent shape, coarse, and fine texture from the cell volume (separately for cytoplasm and nuclei). The resulting features are combined in one MorphoFeatures vector that is used for the subsequent analysis. (B) Training procedure for the shape features. A contrastive loss is used to decrease the distance between the feature vectors of two augmented views of the same cell and increase the distance to another cell. (C) Training procedure for the coarse and fine texture features (here illustrated by coarse texture). Besides the contrastive loss, an autoencoder loss is used that drives the network to reconstruct the original cell from the feature vector. distinguish ultrastructural elements (organelles and inclusions, nuclear and cytoplasm texture, etc.) and an automated segmentation of 11,402 cells and nuclei ( Figure 1A). Additionally, whole-animal gene expression maps are available that cover many differentiation genes and transcription factors. Such a high number of morphologically and genetically diverse cells can make the initial exploratory analysis difficult. We designed MorphoFeatures to enable unbiased exploration of morphological variability in the animal on both cellular and tissue level; and indeed our training procedure yields 480 features that extensively describe each cell in terms of its cytoplasm and nucleus shape, coarse texture, and fine texture (80 features for each category (Pape et al., 2022) in Fiji (Schindelin et al., 2012).

MorphoFeatures allow for accurate morphological class prediction

82Good morphological features should distinguish visibly separate cell groups present in the data. To estimate the representation quality of our MorphoFeatures, we quantified how well they can be used to tell such groups apart. We took the morphological cell class labels available in the dataset, proofread, corrected, and expanded them. These labels include seven general classes of cells: neurons, epithelial cells, midgut cells, muscle cells, secretory cells, dark neurosecretory cells, and ciliary band cells ( Figure 2A) with ~60 annotated cells per class in the whole volume. It is worth noting that these cell classes were chosen based on visual morphological traits and do not necessarily represent genetically defined cell type families (Arendt et al., 2019). For example, while ciliary band cells are a small narrow group of morphologically homogeneous cells that likely constitute one cell type family, secretory cells were defined as cells with abundant organelles/inclusions in their cytoplasm that could indicate secretion, spanning a wider range of morphologies and, potentially, genetically defined cell types. We extracted MorphoFeatures by passing all the cells through the neural network trained as described above ( Figure 1A) and used them as an input to train a logistic regression classifier to predict the above-mentioned cell classes. This classifier has few parameters and can be trained even on the modest number of labels we have available. If any subset of the features strongly correlates with a given cell class, the model will show high performance. A classifier with MorphoFeatures achieved an accuracy of 96%, showing that the learned features are sufficient to distinguish broad morphological classes. To better understand remaining inaccuracies, we show the errors made by the classifier in Figure 2B and Figure 2-figure supplement 1A. This reveals, as expected, that while morphologically homogeneous classes can be easily separated, the classifier tends to confuse some secretory cells with other types (midgut and epithelial cells) that are also difficult to discern by eye and might well be mis-annotated. It also confuses the general neuron class with neurosecretory cells that represent a subclass of neurons.

83To illustrate large-scale performance of the broad cell type classification model, we show its predictions on the whole animal in Figure 2C and D and Figure 2-figure supplement 1B. These results demonstrate that MorphoFeatures are sufficiently expressive to enable training a generalisable model from a small number of labels, taking epithelial cells as a showcase: while the model was trained exclusively on the cells of the outer animal surface, it successfully predicted the cells outlining the gut opening and the chaetae cells as epithelial as well. Even more convincingly, the model predicted some cells in the midgut region as neurons, which after careful visual examination were indeed confirmed to be enteric neurons.

84To explore to which extent each of the morphology components (e.g. cell shape or fine nuclear texture) contributes to predicting the manually labelled cell classes, we ran a similar classification pipeline using these components separately ( Figure 2-figure supplement 2). The results show that, for example, cytoplasm texture is sufficient to tell some classes apart with high precision. However, both coarse and fine cytoplasm texture perform slightly worse on distinguishing neurosecretory cells, in which nuclei occupy almost the whole cell volume. Cell shape is satisfactory to characterise neurons and muscle cells but shows inferior performance on epithelial and secretory cells, which display a great variety of cell shapes. Surprisingly, nuclear fine texture features correctly distinguish, among other classes, muscle cells, suggesting that this class has characteristic chromatin texture.

85In Vergara et al., 2021, morphological classification of cells was performed based on manually defined features, including descriptors of shape (e.g. volume, sphericity, and major and minor axes), intensity (e.g. intensity mean, median and SD), and texture (Haralick features) extracted from the cell, nucleus, and chromatin segmentations, with 140 features in total. To compare these explicitly defined features with implicitly learned MorphoFeatures, we passed them through the same evaluation pipeline yielding a classifier which achieves the accuracy of 94%, in comparison to 96% achieved by MorphoFeatures. The classifier mostly made similar mistakes but performed worse on the classes of muscle and epithelial cells. Both sets of features demonstrate high accuracy on the broad morphological type classification task. For a more detailed comparison, we turn to a different task which allows us to implicitly, but quantitatively, evaluate how well the features group similar cells together.

86We use the metric introduced in Vergara et al., 2021 that is based on the fact that the animal is bilaterally symmetric, thus almost all the cells on one side of the animal will have a symmetric partner. The metric estimates how close a given cell is to its potential symmetric partner in the morphological feature space in comparison to all the other cells in the animal (see Materials and methods). According to this metric, our MorphoFeatures are 38% more precise in locating a symmetric partner than the ones from Vergara et al., 2021, showing the widely accepted superiority of neural network extracted features to explicitly defined ones.

MorphoFeatures uncover groups of morphologically similar cells

87Comprehensive analysis of morphological features should enable the grouping of cells with similar morphology, which may represent cell types. We investigated the grouping induced by Morpho-Features by projecting the features of all the animal cells onto 2D space using the dimensionality reduction technique UMAP (McInnes et al., 2018). To explore the quality of our representations, we repeatedly took a random cell from the animal and visualised its three closest neighbours ( Figure 3A). This shows that cells in close proximity in the feature space appear highly visually similar and might represent cell types at the morphological level. For example, a group of secretory cells in which the cytoplasm is filled with round electron-transparent vesicles (upper green panel) corresponds to the 'bright droplets' cells from Verasztó et al., 2020. Another group of secretory cells has an extensive endoplasmic reticulum (ER) surrounding the nucleus with a prominent nucleolus (lower green panel) and represents parapodial spinning gland cells (Verasztó et al., 2020). One can also see clear groups of flat developing midgut cells (brown panel), short muscles (red panel), ciliary band cells on the outer animal surface (yellow panel) as well as extended flat and short round epithelial cells (orange panels). Another interesting observation is that even though the neurite morphology is not taken into account, neurons show remarkable diversity based on soma morphology only (blue panels). Careful examination of a group of cells, initially labelled as neurons, that are located next to the epithelial cells on the UMAP projection (upper right blue panel) revealed that these cells are sensory cells that extend their processes to the epithelial surface.

88To explore the structure of the MorphoFeatures space, we performed hierarchical clustering of all cells. In the first clustering round, we split cells into 15 broad morphological groups ( Figure 3B). Cluster content could be revealed through available annotations and visualisation with the Platy-Browser (Pape et al., 2022; Figure 3B): Clusters 1-8 represent different groups of neurons; 9-11 epithelial cells; 12 and 13 are muscles; 14 midgut cells; while cluster 15 was further subclustered into secretory cells (subcluster 1) and ciliary band cells (subcluster 2). MorphoFeatures can thus guide the morphological exploration of a whole-animal volume, facilitating the discovery and annotation of morphologically coherent groups of cells ( Figure 3B). For example, the foregut epithelial cells are distinct from the epithelial cells of the outer animal surface and chaetae cells (clusters 9, 11, and 10, respectively). Separate groups are also formed by different types of neurons, for example, foregut neurons (cluster 4).

Morphological clusters have distinct gene expression profiles

89To further describe the morphological clusters, we took advantage of the whole-animal cellular gene expression atlas available for Platynereis (Vergara et al., 2021), containing more than 200 genes mapped onto the EM volume. We looked for genes that are highly expressed in a given cluster, while also being specific for this cluster -having low expression in the other cells of the animal.

90Many of our clusters show a clear genetic signature ( Figure 4A, Figure 4-figure supplement 1). Among the neurons, cluster 5 shows the most specific gene expression including the Transient receptor potential (Trp) channels pkd2, trpV4, and trpV5, and the bHLH transcription factor asci, which demarcate sensory cells of the palpal, antennal, and cirral ganglia (Vergara et al., 2021). Cluster 1 shows specific expression of the homeodomain transcription factors lhx6 and phox2 and an ap2 family member, while cluster 6 composed of dark neurosecretory cells shows specific expression of two neurosecretion markers, atrial natriuretic peptide receptor anpra and prohormone convertase phc2, identifying these as brain parts of the circular and apical nervous system, respectively (Vergara et al., 2021;Arendt, 2021). Cluster 8, another neural cluster, is enriched for the oxidative stress marker cytoglobin (globin-like; Song et al., 2020) and the bHLH transcription factor mitf. Subclustering revealed three subclusters, one of which represents rhabdomeric photoreceptors of the adult eye ( Figure 3B, subcluster 8.1) that specifically express mitf and globin-like. An average cell in this subcluster ( Figure 4B) shows abundant black inclusions. The second subcluster (8.2) contains pigment cells with black pigment granules. Cells in the third subcluster (8.3) are located in the midgut, with a smooth oval shape, neurite extensions and nuclei taking up the most cell volume ( Figure 4C and D) -in striking contrast to other midgut cells but resembling neurons, making it likely that these cells some clusters, the cells comprising the cluster are shown in the animal volume to visualise the cell type. For example, cluster 6 precisely picks out the dark neurosecretory cells, while cluster 14 corresponds to the midgut cells (see Text for more details). Scale bars: 10μm.

91The online version of this article includes the following figure supplement(s) for figure 3: represent enteric neurons previously postulated on the basis of serotonin staining (Brunet et al., 2016). Among the epidermal cells, the outer cluster 11 is enriched for protocadherin (pcdh15) and neurotrypsin (ntrps), whereas cluster 9 representing foregut epidermis shows high specificity for the bHLH transcription factor sim1 and the homeodomain factor pou3 (brn124, known to be expressed in stomodeal ectoderm in sea urchin; Cole and Arnone, 2009). For the muscles, the specific expression of striated muscle-specific myosin heavy chain mhcl4 in cluster 12 denotes the group of striated somatic muscles, while its absence in cluster 13 indicates that the foregut muscles have not yet switched to expressing striated markers (Brunet et al., 2016). Instead, the high and specific expression of the calexcitin-like sarcoplasmic calcium-binding protein Scp2 (calexcitin2; White et al., 2011), calmodulin, and of the Boule homologue Boll (boule-like) in cluster 13 suggests a calcium excitation and/or sequestration mechanism specific for foregut muscles. Finally, the cluster of midgut cells (cluster 14) specifically expresses the forkhead domain transcription factor foxA (for), a gut developmental marker (Boyle and Seaver, 2008) and TrpV-c, another Trp channel paralogue of the vanilloid subtype with presumed mechanosensory function.

92Beyond that, we noted considerable genetic heterogeneity in the midgut cluster. Finer clustering ( Figure 5) revealed one subcluster with strong expression of the smooth muscle markers non-muscle-mhc and mrlc2, and another expressing a chitinase related to chitotriosidase (nov2) and the zinc finger transcription factor Prdm16/mecom, known to maintain homeostasis in intestinal epithelia (Stine et al., 2019). Visualising the cells belonging to each subcluster and the specifically expressed genes in the PlatyBrowser ( Figure 5E) revealed distinct territories in the differentiating midgut, which we interpret as midgut smooth musculature and digestive epithelia. We also detected an enigmatic third cluster located outside of the midgut, in the animal parapodia, comprising cells that resemble midgut cells morphologically ( Figure 5D). For this subcluster, the current gene repertoire of the cellular expression atlas did not reveal any specifically expressed gene.

MorphoFeatures correspond to visually interpretable morphological properties

93Neural networks are often referred to as 'black boxes' to signify that it is not straightforward to trace learned features or decisions back to particular input properties. To examine whether it is possible to understand which properties of cells learned by our network distinguish the discovered morphological groups, we first identified MorphoFeatures that have high values specific to each cluster (Figure 6figure supplement 1). Then for a set of characteristic features, we visualised cells that correspond to the maximum and minimum value of the corresponding feature ( Figure 6). Visual inspection showed that many of them can be matched to visually comprehensible properties.

94For example, cytoplasm coarse texture feature 21 ( Figure 6, upper left), which distinguishes the outer epithelial cells (cluster 11), shows its minimal value in secretory cells, which contain multiple highly distinct types of texture, and its maximal value in the cells crowded with small vesicles and cisternae on the surface of the animal. The cluster of enteric neurons (cluster 8.3) strongly differs from other neurons by nuclear coarse texture feature 4 ( Figure 6, upper right), which contrasts nuclei with large amount of heterochromatin often attached to the nuclear lamina to nuclei with a high amount of euchromatin and prominent nucleoli. Cytoplasm fine texture feature 50 ( Figure 6, middle left), characteristic to the midgut cells (cluster 14), is the lowest in cells with a small stretch of homogeneous cytoplasm with mitochondria and has its peak in cells with abundant Golgi cisternae and mediumsized mitochondria. Rhabdomeric photoreceptors of the adult eye (cluster 8.1) display specific nuclear fine texture feature 7 ( Figure 6, middle right) that differentiates between nuclei with smooth and rather grainy texture. Cell shape feature 14 ( Figure 6, lower left) has its minimal value found in beakershaped cells with smooth surface and its maximal value in rather round cells with extremely rugged surface and is specific for ciliary band cells (cluster 15.2). Foregut muscles (cluster 13) can be described using nuclear shape feature 66 ( Figure 6, lower right), having one extreme in nuclei with a small compartment with a rough surface (as a result of a segmentation error) and the other extreme in elongated flat nuclei. Adding neighbour morphological information helps to identify tissues and organs

95Most cells do not function in isolation but rather form tissues, i.e., groups of structurally and functionally similar cells with interspersed extracellular matrix. We set out to systematically identify tissues with a new feature vector assigned to each cell that takes into account information about the morphology of neighbouring cells. For this, we combined the MorphoFeatures of a cell with the average Morpho-Features of its immediate neighbours, yielding a feature vector that represents the morphology of both the cell and its surrounding, which we refer to as MorphoContextFeatures. Applying the representation analysis described before, we find that proximity in MorphoContex-tFeature space no longer reflects morphological similarity only but rather identifies neighbouring groups of morphologically similar cells (whereby the neighbouring groups can be morphologically dissimilar). In other words, we now identify different tissues that together constitute organs composed of various tissues (Figure 7). For example, a separate assembly of groups of cells in the lower part of the UMAP projection represents the animal foregut subdivided into its constituting tissues comprising foregut neurons (lower blue panel), foregut muscles (lower beige panel), and foregut epithelium (left yellow-green panel). Next to this, we identify a group of muscles surrounding the foregut (left red panel). For the nervous system, adding neighbourhood information helps distinguishing cirral, palpal, and dorsal ganglia (three upper right panels, from left to right), as well as the ventral nerve cord and peripheral ganglia (two lower right panels). To benchmark the quality of this grouping, we clustered all the cells in the MorphoContextFeature space (see Materials and methods) and compared the neuron clusters to both manually segmented ganglionic nuclei and to the genetically defined neuronal clusters taking into account available gene expression in the cellular atlas (Vergara et al., 2021; Figure 8A and B). Notably, manual segmentation of brain tissues relied on visible tissue boundaries and thus has lower quality in the areas where such boundaries are not sufficiently distinct.

96In essence, all three ways of defining ganglia lead to very similar results ( Figure 8B), yet MorphoC-ontextFeature clustering appeared to be the most powerful. Gene clustering failed to distinguish the circumpalpal ganglion, defined both by manual segmentation and MorphoContextFeature clustering, due to the lack of distinct gene expression in the atlas. Manual segmentation failed to distinguish between the dorso-posterior and dorsal-anterior ganglionic nuclei due to the lack of distinct tissue boundaries. These are well defined by gene clustering and subdivided even further by MorphoCon-textFeature clustering. Unaware of the physical tissue boundaries, MorphoContextFeatures sometimes led to ambiguous assignment of cells neighbouring other tissues, especially cells with strongly different morphology. Such noisy assignment can be noticed, for example, in the neurons bordering muscle cells on the boundary of the cirral ganglia and in the centre of the brain.

97To further examine the contribution of incorporating cellular neighbourhood morphology, we visualise the discovered foregut tissues and ganglia on the MorphoFeatures representation (Figure 8figure supplement 1 and Figure 9-figure supplement 1). This shows that while some of the tissues, such as palpal ganglia or foregut epithelium, are composed of cells of one morphological type, others, e.g., circumpalpal ganglia or infracerebral gland, comprise cells with different morphology and could only be detected when taking into account cellular context as well.

Unbiased exploration of foregut tissues

98To further illustrate how MorphoContextFeatures can assist an unbiased exploration of an animal EM volume, we focused on the foregut. Subclustering whenever suitable ( Figure 9A; see Materials and methods), the resulting clusters revealed various foregut tissues including foregut epidermis, ganglia, inner musculature, and a prominent muscle surrounding the foregut. We also found a tissue of secretory neuron-like cells that surround the foregut like a collar ( Figure 9B and C, in green).

99of the genes shown to be differentially expressed in the two subclusters, plotted on the UMAP representation. (D) The location (upper panel) and an example cell (lower panel) of the subcluster located in the animal parapodia. Scale bars: upper panel -25μm, lower panel -5μm. (E) Cells belonging to the two cell types (left panels) and the genes differentiating them (centre and right panels) are visualised in the animal volume, with colour representing gene expression overlayed on the electron microscopy (EM) plane view. Scale bar: 10μm. Further inspection revealed that the latter structure is located underneath the brain neuropil and close to the neurosecretory endings of the neurosecretory plexus (Verasztó et al., 2020) and is bounded by thin layers of longitudinal muscle fibres on both the outer and the inner surface ( Figure 9-figure supplement 2A). The location of the structure indicated it might be the differentiating infracerebral gland -a neurosecretory gland located beneath the brain assumed to play a role in sensing blood glucose levels (Backfisch, 2013;Baskin, 1974;Hofmann, 1976;Golding, 1970). The organ is leaf-shaped and lays between the posterior pair of adult eyes (Figure 9- Figure 6. Visualisation of the learned features. For each feature, four cells with a minimal (blue) and four cells with a maximal (red) value of the feature are shown, see text for detailed analysis. Shown are cytoplasm coarse texture feature 21, nuclear coarse texture feature 4, cytoplasm fine texture feature 50, nuclear fine texture feature 7, cytoplasm shape feature 14, and nuclear shape feature 66. Scale bars: coarse texture -2μm, fine texture -1μm.

100The online version of this article includes the following figure supplement(s) for figure 6: supplement 2B) as also described in Backfisch, 2013 and borders a cavity likely to be a developing blood vessel (Figure 9-figure supplement 2C). In comparison to the foregut neurons that express sodium channel scn8aa, the infracerebral gland cells specifically express homeobox protein onecut/ hnf6 ( Figure 9D and E). We also noted that the tissue stains positive for EdU applied between 3 and 5 dpf, indicating that it is still proliferating. We then identified the prominent muscles surrounding the foregut as the anterior extension of the axochord (Lauri et al., 2014). Visualising the genes specifically expressed in these muscles, we noticed specific expression of the type I collagen gene col1a1, a marker for axochordal tissue, and of muscle junctional gene junctophilin1 ( Figure 9F). An anterior extension of the axochord around the foregut has been observed in several species and is described in Lauri et al., 2014;Brunet et al., 2016;Nielsen et al., 2018.

Discussion

101We presented an automated method of extracting comprehensive representations of cellular morphology from segmented whole-animal EM data. In stark contrast to the currently available methods, ours refrains both from specifying features explicitly and from predefining a concrete task that might skew the method towards extracting specific features: putting emphasis on some features may bias descriptions towards specific morphologies or cell types, hindering exploratory analysis. To obtain extensive generally useful representations, we rely on the latest progress in self-supervised deep learning and set only two criteria for the extracted features: (1) they have to be sufficiently detailed to allow reconstructing the original cell volume and (2) they have to bring visually similar cells in feature space closer to each other than dissimilar ones. We train a deep-learning pipeline optimised for these two conditions and show that it produces rich cellular representations, combining shape-, ultrastructure-, and texture-based features. More precisely, we show that the obtained representations (MorphoFeatures) capture fine morphological peculiarities and group together cells with similar visual appearance and localisation in the animal. Clustering of cells in the MorphoFeature space and taking advantage of an existing gene expression atlas with cellular resolution, we show that the obtained clusters represent units with differential and coherent gene expression.

102Both for morphological type and for tissue detection, we illustrate how MorphoFeatures can facilitate unbiased exploratory analysis aimed at detecting and characterising unusual phenotypes or unusual cell neighbourhoods. Moreover, we show quantitative superiority of MorphoFeatures over a broad range of manually defined features on the tasks of cell classification and symmetric partner detection. We also show that, despite being learned implicitly, MorphoFeatures still correspond to visually understandable properties and can often be interpreted. Finally, adding morphological information from the neighbouring cells (MorphoContextFeatures), we reveal the power of our approach to detect local groups of cells with similar morphology that represent tissues.

103Since our pipeline is based on the fast-evolving field of self-supervised deep learning, we expect it to further improve with its general advancement. For example, a promising direction are models, such as Grill et al., 2020, that only rely on positive samples and remove the need to define which cells belong to a different type. Besides MorphoFeatures, we also believe that MorphoContextFeatures, which incorporate neighbourhood information, will potentially benefit from state-of-the-art selfsupervised techniques such as contrastive-learning techniques on graphs (Hassani and Khasahmadi, 2020;Velickovic et al., 2019). Additionally, we expect hardware improvement, i.e., GPU RAM size, to allow training bigger models on larger texture patches of higher resolution that might further refine the quality of morphological representations. Another interesting direction enabled by the modularity of our pipeline is to integrate data from other modalities. Our features currently integrate shape and texture information of cells, but one could also envision enriching cellular descriptions by adding different types of data, e.g., transcriptomics, proteomics, or metabolomics, in a similar manner.

Versatility of the MorphoFeatures toolbox

104We envision our pipeline to enable, for the first time, fast systematic investigation of large EM volumes that involves consistent grouping and characterisation of morphological types, discovering particular phenotypes and neighbourhoods, as well as localising cells or tissues in an animal volume that are visually similar to cells or groups of cells of interest. Moreover, we expect MorphoFeatures to be useful for studies where several image volumes of the same species are acquired, be it another sample, a varying phenotype, or a different developmental stage. In such cases, training the pipeline on multiple volumes simultaneously to produce sample-independent features would result in morphological representations that can be used to map cells to their corresponding partners in another volume, enabling unbiased comparative analysis at scale. In addition, in case the other volumes are not segmented, one could use the fine texture part of MorphoFeatures to locate patches with phenotypic characteristic signature or cells with distinct ultrastructure (e.g. muscles and secretory cells). Using fine texture descriptors in such cases can also facilitate further segmentation since the segmentation of the previous volume can be used to define constraints of which textures can co-occur in the cells of the animal. However, given the high sensitivity of neural networks to intensity variations, it cord. Scale bars: 10μm. (C) Gene expression dot plot of the ganglia defined by MorphoContextFeature clustering.

105The size of the dots shows how much of a cluster expresses a gene; the colour shows how much of the expression of a gene is confined to a cluster (see Materials and methods). (D) Some of the genes shown to be differentially expressed in the ganglia defined by MorphoContextFeature clustering, plotted on the UMAP representation.

106The online version of this article includes the following figure supplement(s) for figure 8: will be essential to avoid non-biological systematic change in the visual appearance of cells such as intensity shifts, both within and between the EM volumes.

107The presented pipeline can also be adjusted for other types of data. For example, since our analysis revealed a high variability in neuronal soma morphologies, it appears reasonable to also apply the pipeline to brain EM volumes, where MorphoFeatures could supplement neuron skeleton features for more precise neuronal morphology description. We also expect the approach to contribute to the analysis of cells in other volumetric modalities, such as X-ray holographic nano-tomography (Kuan et al., 2020). For light microscopy with membrane staining, we expect the shape part of the Morpho-Features pipeline to be directly applicable and a useful addition to existing analysis tools. Generally, the versatility of the pipeline is enhanced by its modularity that makes it possible to adapt different parts (e.g. cell shape or nucleus fine texture) to datasets where not all the morphological components are desired or can be extracted.

Identification of cell types and cell type families with MorphoFeatures

108Any attempt to define cell types morphologically has so far been hampered by the selection of relevant properties. What are the morphological features that are best suited for recognising cell types? Regarding neurons, the shapes of dendrites and axons, soma size, and spine density have been measured, in combination with physiological properties including resting potential, biophysical properties, and firing rate (Zeng and Sanes, 2017). Volume EM has recently allowed considerable expansion of morphometric parameters, including various shape, intensity, and texture features (Vergara et al., 2021). Using these numerous parameters, it is possible to discern general categories such as neurons, muscle, or midgut cells; yet they do not provide further resolution within these groups. Comparing the MorphoFeatures representations to the predefined features (Vergara et al., 2021) hints at supreme resolution power that appears to distinguish morphological groupings down to the cell type level (Figure 4-figure supplement 2). For example, the subclusters of rhabdomeric photoreceptors of the adult eye and enteric neurons can not be identified in the explicit features representation. Furthermore, the cluster of foregut muscles revealed by the MorphoFeatures appears to be split, with some cells being found closer to striated muscles and some residing between the groups of neurons and dark neurosecretory cells.

109Most importantly, the cell clusters identified in MorphoFeature space appear to come closest to genetically defined cell types, as demonstrated here, among others, for different types of mechanosensory cells or cell types of the apical nervous system. Interestingly, the MorphoFeatures also unravel morphological cell types without a genetic match in the cell type atlas (such as the enteric neurons, see above). This is most likely due to the yet limited coverage of the atlas and expected to improve with the continuous addition of genes to the atlas. In particular, the integration of other multimodal omics datasets such as single cell transcriptomics data will be highly rewarding to improve the match between morphological and molecularly defined cell types, which is the ultimate aim of cell type characterisation and categorisation (Zeng and Sanes, 2017).

Towards an unbiased whole-body identification of tissues and organs

110The current revolution in the generation of giant volume EM datasets including representations of entire bodies calls for new strategies in the automated processing and comparison of such datasets. This not only involves segmentation and characterisation at the cellular level but also requires the automated identification of discernable structures at the level of tissues and organs. So far, the recognition of tissues in larger volumes was achieved by manual segmentation. We now present a powerful new algorithm to recognise tissues and organs via their co-clustering in the MorphoContextFeature expression dot plot of the foregut region clustering. The size of the dots shows how much of a cluster expresses a gene; the colour shows how much of the expression of a gene is confined to a cluster (see Materials and methods). The genes mentioned in the text are enboxed. (F) The genes specific to the axocord muscles, visualised on the animal volume. Scale bars: 10μm.

111The online version of this article includes the following figure supplement(s) for figure 9: space, which takes into account similarities between cell neighbourhoods. Using this algorithm, we reproduce and partially outperform tissue recognition via manual segmentation -as exemplified for the ganglionic nuclei of the nereid brain. Beyond that, we present a comprehensive account of foregut tissues, without prior manual segmentation. This analysis reveals a rich collection of tissues including an anterior extension of the axochord surrounding the foregut (Lauri et al., 2014) and the infracerebral gland (Baskin, 1974;Golding, 1970), an adenohypophysis-like neurosecretory tissue that we identify as anterior bilateral extensions of the foregut roof.

112While the manual segmentation of tissues mostly relies on the detection of tissue boundaries, our automated tissue detection equally processes the morphological similarities of its constituting cells. This enables tissue separation even in cases where morphological boundaries appear to be absent, as is the case for the anterior and posterior dorsal ganglionic nuclei, which are lacking a clear boundary but are composed of morphologically different cell types that are also genetically distinct (Vergara et al., 2021).

Conclusion

113The revolution in multi-omics techniques and volume EM has unleashed enormous potential in generating multimodal atlases for tissues as well as entire organs and animals. The main unit of reference in these atlases is the cell type, which has been defined, and is manifest, both molecularly and morphologically. Our work now provides a versatile new tool to recognise cell types in an automated, unbiased, and comprehensive manner solely based on ultrastructure and shape. For the first time, the MorphoFeatures will allow us to compare and identify corresponding cell types in datasets of the same species, but also between species, on purely morphological grounds.

114Furthermore, the MorphoContextFeatures automatically recognise tissues and organs across entire bodies, opening up new perspectives in comparative anatomy. Without previous knowledge, we can obtain the full complement of tissues and organs for a given specimen and quantitatively compare them to those of other specimens of the same or other species. In combination with cell type-, tissue-, and organ-specific expression data, this will enable us to identify corresponding traits in an unbiased manner and with unprecedented accuracy.

Data and preprocessing Data

115We used the dataset of the marine annelid P. dumerilii at late nectochaete stage (6 dpf) from Vergara et al., 2021. The dataset comprised an SBEM volume of the complete worm in 10 × 10 × 25 nm resolution, 3D cell and nucleus segmentation masks as well as Whole Mount In-Situ Hybridisation (WMISH) gene expression maps. The segmentation contains 11,402 cells with nuclei that belong to multiple genetically and morphologically distinct cell types. It is important to note that for neurons only somata were segmented since the imaging resolution did not allow for neurite tracing. The gene expression maps cover mainly differentiation genes and transcription factors, which were registered onto the EM volume, exploiting high stereotypy of the Platynereis at this stage of development. Gene expression values were also assigned to the EM segmented cells. The maps contain 201 genes and 4 EdU proliferation stainings. We refer to Vergara et al., 2021 for further details. Since the intensity correction algorithm that was used in the EM volume performed unreliably in regions close to the boundaries of the volume in the z-axis, we excluded all cells located within the region of uncertain intensity assignment quality. These regions correspond to parts of the animal's head and the pygidium.

Preprocessing

116The EM dataset is used to extract the three morphological components separately for cytoplasm and nuclei as follows. Due to the limitations of the GPU memory, for the coarse texture, a central crop is taken from a downsampled version of the data (80 × 80 × 100 nm). The centre of mass of the nucleus is determined, and a bounding box of size 144 × 144 ×144 pixels (cytoplasm) or 104 × 104 × 104 (nuclei) is taken around it. During prediction, the bounding box is increased to 320 × 320 × 320 (cytoplasm) and 160 × 160 × 160 (nuclei) to fit more information. Fine texture patches have a higher resolution (20 × 20 × 25 nm) and are taken separately from cytoplasm and nucleus. For this, the bounding box surrounding cytoplasm or nucleus is split into cubes of 32 × 32 × 32 pixels, and only those cubes are considered which are less than 50% empty. For both coarse and fine texture, the data is normalised to the range of [0, 1], and for cytoplasm crops, the nuclei are masked out and vice versa.

117In order to obtain point clouds and normals of the membrane surfaces, we first converted the segmented 3D voxel volumes into triangular meshes. More specifically, we first applied the marching cubes algorithm Lorensen and Cline, 1987;van der Walt et al., 2014 followed by Laplacian smoothing (Schroeder et al., 1998) to obtain smooth triangular surface meshes. These meshes were then simplified and made watertight using Stutz and Geiger, 2020;Cignoni et al., 2008. Having obtained smooth triangular meshes enables us to compute consistent normals and to apply complex deformations to the underlying surface. During training and inference, the meshes and their surface normals are sampled uniformly to be then processed by the neural network.

Unsupervised deep-learning pipeline

118This section describes our proposed algorithm in more detail. The training and prediction pipeline is implemented in Pytorch (Paszke et al., 2019). On a high level, our model consists of six encoder networks which leverage graph convolutional as well as regular convolutional layers in order to learn shape and texture aspects of a cell's morphology. We are using self-supervised learning in combination with stochastic gradient descent in order to obtain good network parameters. The objective that is optimised is a weighted sum of the NT-Xent loss and the mean squared error and can be interpreted as an unbiased proxy task. We will detail and elaborate on these aspects in the following sections.

Neural network model

119The proposed network, as depicted in (Figure 1A), contains six encoders which are encoding shape, coarse, and fine-grained texture of cells and nuclei.

120The shape encoder takes as input a set of points in the form of 3D Euclidean coordinates as well as the corresponding normals (see Data and preprocessing) and outputs an N-dimensional shape feature vector. The network itself is a DeepGCN model (Li et al., 2019), which is a deep neural network for processing unstructured sets such as point clouds. Conceptually, it consists of three building blocks. In the first block, k-nearest neighbour graphs are built dynamically in order to apply graph convolutions. This can be interpreted as pointwise passing and local aggregation of geometric information which is repeated multiple times. In the second block, the pointwise aggregated geometric information is fused by passing it through a convolutional layer followed by a max pooling operation that condenses the information into a high-dimensional latent vector. Finally, the obtained latent vector is passed through a multilayer perceptron to obtain the shape component of the overall feature vector.

121The encoding of fine texture details and coarser contextual information is done using the encoder of a U-Net (Ronneberger et al., 2015). The fully convolutional network reduces spatial information gradually by employing three blocks that consist of 3D convolutional layers with ELU activations (Clevert et al., 2015) separated by 3DMaxPooling layers. The number of feature maps starts with 64, increases twofold in each block, and afterwards gets reduced to 80 by an additional convolutional layer followed by an ELU activation. In the end, a global average pooling operation is applied to reduce feature dimensionality from 3D to 2D. To ensure that empty regions of the data are not affecting the final feature vector, they are excluded for this final pooling.

Training

122In order to find suitable representations, we leverage self-supervised contrastive learning (CL; Chen et al., 2020;Hadsell et al., 2006). The idea is to create a representation space in which morphologically similar cells are embedded close to each other, while dissimilar ones are embedded far apart. For learning representations of shape, we follow a purely contrastive approach, whereas for texture representations, we combine the CL objective with an autoencoder reconstruction loss. Both are described in more detail below.

123The training procedure for CL is the same for shape and texture representations. First, we randomly sample a mini batch of cells or nuclei. Two augmented views are then created for each sample in the batch (see Data augmentations) and concatenated to form an augmented batch of twice the size. The augmented batch is passed through the neural network encoder to compute representations. Those representations that share the same underlying sample are considered as positive pairs, whereas the others are considered as negative pairs. The NT-Xent loss is then used to score the representations based on their similarity and, therefore, encourages the network to embed positive pairs closer to each other than negative pairs. For learning shape representations, we first augmented all cell and nucleus meshes using biharmonic deformation fields and as-rigid-as-possible transformations in a preprocessing step (see Data augmentation). More specifically, we computed 10 random views for each membrane surface. The augmented meshes are then used for training, i.e., we compute surface normals and sample 1024 points and their corresponding normals which form the inputs of the shape encoders. In each training iteration, we sampled 48 cells/nuclei, which resulted in a batch size of 96. Adam (Kingma and Ba, 2014) with a learning rate of 0.0002 and a weight decay of 0.0004 was used to update the network parameters. The hyperparameters were obtained by a random search.

124In order to learn representations of texture, we combine the NT-Xent loss with an autoencoder reconstruction objective. The latent representations, taken before the dimensionality reduction step of global average pooling, are further processed by a symmetric decoder part of the UNet network with only one block, which aims to reconstruct the network inputs. The reconstructions are then compared to the original inputs and scored by a mean squared error loss. Additionally, an L2-Norm loss was applied to flattened bottleneck features to restrict the range of possible values. The final loss is thus a weighted sum of the NT-Xent, the mean squared error loss, and the L2-Norm loss. The batch size was set to 12 and 16 for cell and nuclei coarse texture and to 32 for fine texture. For training, we used Adam (Kingma and Ba, 2014) as optimizer with a learning rate of 0.0001 and a weight decay of 0.00005. The model was evaluated every 100 iterations, and the best result was saved with a patience of 0.95. The learning rate was reduced by 0.98 whenever the validation score did not show improvement with a patience of 0.95.

Data augmentation

125A key component for successful contrastive representation learning are suitable data augmentations. In our context, applying augmentations to a cell can be interpreted as creating morphological variations of a cell. By creating positive and negative pairs (cf. previous section), the network learns to distinguish true variations from noise and non-essential ones. It is therefore important to find a suitable set of transformations that distort the right features of a cell and do not change its morphological identity.

126As augmentations for shape, we leveraged biharmonic and as-rigid-as-possible transformations (Botsch and Kobbelt, 2004;Sorkine andAlexa, 2007, Jacobson et al., 2018) as they deform cellular and nuclear membranes in a way that retains most characteristic geometric features of the original surface. In order to compute these deformations, we sample so-called handle regions on the membrane surface. These regions are translated in a random, normal, or negative normal direction. The deformation constraint is then propagated to the rest of the surface either via a biharmonic deformation field or an as-rigid-as-possible deformation. We combine these deformations with random anisotropic scaling, rotations, and/or symmetry transformations.

127To create positive samples for the contrastive training of texture, we used random flips and rotations and elastic transformations of the data.

Inference

128In order to compute the MorphoFeatures representation for the whole animal, we processed each cell's cellular and nuclear shape and texture, as described in previous sections, with our trained networks. For the fine texture patches to get one feature vector per cell, the feature vectors of all the patches from a cell were averaged. Each cell is represented by a 480-dimensional vector that consists of a nuclear and cellular part. Each of these parts consists of a shape, coarse, and fine-grained texture 80-dimensional feature vector. This vector size was found empirically using the bilateral distance as a metric. Vectors of bigger size showed similar performance, but contained more redundant features.

Quantitative feature evaluation

129In this section, we describe our feature evaluation experiments in more detail. In order to assess the quality of MorphoFeatures quantitatively, we conducted cell-type prediction and bilateral pair analysis experiments. We use the same set of explicit features that were used in Vergara et al., 2021 for analysing cellular morphology as a baseline for comparisons.

Explicit feature baseline

130The explicitly defined representation includes shape features (volume in microns, extent, equivariant diameter, major and minor axes, surface area, sphericity, and max radius), intensity features (different quantiles of intensity mean, median, and SD), and Haralick texture features. These features were calculated, whenever appropriate, for cell cytoplasm, nucleus, and chromatin segmentation. The calculated features were taken from Vergara et al., 2021: https://github.com/mobie/platybrowser-project/blob/ main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology.tsv for cellular segmentation and from https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-nuclei/morphology.tsv for nucleus and chromatin segmentation. The UMAP of these features was taken from https://github.com/mobie/platybrowser-project/blob/main/data/1. 0.1/tables/sbem-6dpf-1-whole-segmented-cells/morphology_umap.tsv.

Classification of visibly distinct groups of cells

131In order to verify that MorphoFeatures can distinguish visibly different groups of cells, we evaluated the prediction accuracy of a logistic regression model that was trained on a small dataset of 390 annotated cells taken from Vergara et al., 2021 (Figure 2A). The original annotation contained 571 neurons, 141 epithelial cells, 55 midgut cells, 53 muscle cells, 51 secretory cells, 41 dark cells, and 25 ciliated cells. We first corrected the assignments deemed incorrect by the annotators with expertise in Platynereis cell types. Then for the classes that contained less than 60 cells, we manually annotated more cells. From bigger classes, we selected 60 cells, selecting the most morphologically diverse ones when possible. For ciliated cells, we were only able to locate 30 cells in the whole animal.

132First, we computed the MorphoFeatures representation for each cell in the animal (excluding cells with severe segmentation errors) and standardised features across the whole dataset. We then trained and validated a logistic regression model using a stratified k-folds cross validator with fivefolds. We used the implementations of logistic regression, stratified k-fold from Scikit-learn (Pedregosa et al., 2011) with the following arguments: C=1, solver = 'lbfgs'. To prevent potential overfitting due to the high number of features, we used feature agglomeration (Pedregosa et al., 2011;n_clusters = 100) to reduce the number of similar features.

Bilateral pair analysis

133The criterion of classifying distinct groups of cells in the previous section can be seen as a coarse and global way of evaluating MorphoFeatures. In this section, we describe how we used the animal's bilateral symmetry to have a more fine-grained measure for quantitatively evaluating nuanced morphological differences. The measure, which we will refer to as bilateral distance, was introduced in Vergara et al., 2021 and leverages the fact that most cells in the animal have a symmetric partner cell on the other side of the mediolateral axis. The bilateral distance is computed in the following way: first, we determine for each cell c a group of N potential partner cells {c 1 , , c N } on the opposite side. We then compute a ranking based on the Euclidean distances ∥c − c∥ in feature space between cell c and all other cells c ̸ = c . Since c 's symmetric partner has the same morphology, up to natural variability, it should be among the closest cells in the ranking. We then determine the highest ranked partner cell as rank(argmin n∈{1,...,N} ∥c − cn∥) . In doing this for all cells, we create a list containing the ranking positions of cells to their symmetric partner. The bilateral distance is then defined as the median of this list and can be interpreted as a measure of how close two morphologically very similar cells are on average in feature space.

Adding neighbour morphological information

134This section describes how neighbourhood information was incorporated into MorphoFeatures in order to obtain MorphoContextFeatures. First, we built a region adjacency graph from the cell segmentation masks using scikit-image (van der Walt et al., 2014). The obtained graph reflects the animal's cellular connectivity, i.e., cells are represented by nodes in the graph, and nodes are connected by an edge if the corresponding cells are neighbours. We then assign node attributes by mapping the MorphoFeatures representation of a cell to the corresponding node. Neighbourhood features are then obtained by computing the mean over a node's MorphoFeatures vector and the MorphoFeatures vectors of its surrounding neighbours. Finally, a cell's neighbourhood features are concatenated with the cell's MorphoFeatures to obtain the MorphoContextFeatures representation.

135We benchmarked multiple methods for aggregating feature vectors of neighbouring cells, including taking the mean, the median, and approaches based on graph neural networks. Among these methods, taking the mean showed to be the best tradeoff between performance and simplicity. Compared to taking the median, the mean features showed to give a higher accuracy on predicting morphotypes and have a lower bilateral distance. The features extracted by graph neural networks exhibited unstable behaviour, both in predictiveness of morphotypes as well as bilateral distance.

Feature analysis UMAP representation analysis

136Visualisation was done using the UMAP package (McInnes et al., 2018) with the following parameters: Euclidean metric, 15 neighbours, and 0 minimal distance. Cell metadata, such as annotated types, animal regions, or gene expression, was plotted on the resulting UMAP.

Clustering

137Cell clustering was done according to the following procedure. First, the features were standardised to zero mean and unit variance. Then, following Dubourg-Felonneau et al., 2021, a weighted k-neighbour graph was constructed from MorphoFeatures representations of all the animal cells using the UMAP algorithm (McInnes et al., 2018) with the following arguments: n_neighbours = 20, metric='Euclidean', and min_dist = 0. Afterwards the Leiden algorithm (Traag et al., 2019) for community detection was used to partition the resulting graph, using the CPMVertexPartition method and a resolution parameter of 0.004. For more fine-grained clustering, the resolution was increased to 0.1 to split apart secretory and ciliary band cells, 0.2 to split photoreceptors and enteric neurons, 0.07 to split the midgut cluster, 0.005 for muscle neighbourhood cluster (n_neighbours for the UMAP clustering was adjusted to 10), and 0.01 for splitting foregut neurons and epithelial cells.

138One of the clusters was discarded since visual examination showed it contained only cells with split segmentation errors that 'cut' through the nucleus area along one of the axes (examples shown in Figure 3-figure supplement 1). Other types of segmentation errors in the dataset mostly did not influence the clustering quality for multiple reasons. First, most errors are rather randomly distributed and not consistent, meaning the size of falsely attached fragments is highly variable, and the location of segmentation splits is not consistent. Secondly, many of the errors are cell type specific. For example, midgut cells often got merged with midgut lumen, (Figure 3-figure supplement 2, dark green) and muscle cells often experienced splits or merges of other muscle pieces (Figure 3-figure supplement 2, dark and light orange). Small merges that are not cell type specific (Figure 3-figure supplement 2, light green) also minimally affected the assignment. However, substantial merges could lead to a cell being grouped with a different cell type, for example, a neuron that got merged with a piece of epithelial cell bigger than the neuron size ( Figure 3-figure supplement 2, yellowgreen) got grouped together with epithelial cells, not neurons.

139To visualise average shape and texture of a cluster (4B,C), a median feature vector was computed across the cluster, and the cell with the feature vector closest to the median one was taken as the average cell.

Gene expression analysis

140To produce the cluster gene expression 'dot plots' (Figures 4A, 5B, 8C and 9E), the gene expression values for each cell were taken from Vergara et al., 2021 at https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/genes.tsv. Similar to Vergara et al., 2021, for each cluster and for each gene, we calculated three values: (A) the mean expression in the cluster, (B) the fraction of the total animal/region expression within this cluster (the sum of expression in this cluster divided by the sum of the expression in the whole animal or the selected region), and (C) the specificity defined as C = 2AB/(A + B) . Intuitively, A indicates how much of the cells in a given cluster express a given gene, B shows how selective this gene for this cluster is, and C is a harmonic mean of the two values. To create a dot plot, only the genes with C value above 0.15 were used. For the neuron clusters 1, 3, and 5 ( Figure 4A), the threshold was increased to 0.2 due to a high number of specifically expressed genes available. For the midgut clusters ( Figure 5) to show only the genes differing between the two clusters, the genes were removed, where the specificity was above 0.15 in both clusters but differed by less than 0.4. The size of the dots in the plots reflects A , and the colour corresponds to B . The cluster with the most gene expression was determined, and the remaining clusters were sorted by their similarity to it. To illustrate some of the genes showing differential expression in these groups ( Figures 5, 8 and 9), the corresponding regions of the UMAP representation were cut out, and these genes were plotted on top.

Feature specificity analysis

141The feature specificity 'dot plots' were generated as follows. The MorphoFeatures of all cells were processed by first clipping the values below -2 and above +2 (less than 5% of values affected) and standardised to the range of [0, 1]. Then three values A , B , and C were calculated similarly to gene expression dot plots. However, since smaller clusters would have smaller sum of any feature, we additionally normalised the value B by diving it by the relative cluster size. To create a dot plot, only the features with C value above 1 were used.

142To illustrate some features specific to clusters ( Figure 6-figure supplement 1), we first selected a set of features from the dot plot with high specificity in a given cluster and low specificity in other clusters. We then showed their extremes with cells that have the respective minimal/maximal value of this feature ( Figure 6). The cells with merge errors of more than half of a cell size were ignored. In order to visualise the 3D cells and nuclei, we selected a 2D view that we presume shows the shape or texture feature common between all four selected cells with minimal or maximal value of the feature.

143Visualising the extremes of various features from the dot plot, we found most features (80-90%) to be relatively easy to interpret. More specifically, 82% shape features, 80% fine texture features, and 90% coarse texture features could be visually mapped to explainable properties in less than 2 min of observing the data. However, when selecting a random subset (10-20 random features) from each morphological component, the number of clearly interpretable features was lower, 65% for fine, 70% for coarse texture, and 45% for shape features.

Ganglionic nuclei

144To compare ganglionic nuclei (Figure 8), we used manually segmented regions from https://github. com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/ ganglia_ids.tsv and https://github.com/mobie/platybrowser-project/blob/main/data/1.0.1/tables/ sbem-6dpf-1-whole-segmented-cells/regions.tsv and gene clusters from https://github.com/mobie/ platybrowser-project/blob/main/data/1.0.1/tables/sbem-6dpf-1-whole-segmented-cells/gene_clusters.tsv (Vergara et al., 2021).

Data visualisation

145We used matplotlib (Hunter, 2007) and seaborn (Waskom, 2021) for plotting the data, MoBIE (Pape et al., 2022) for visualising cells in the EM volume, and vedo (Musy et al., 2022) for visualising meshed cells and tissues. The funders had no role in study design, data collection and interpretation, or the decision to submit the work for publication.

참고문헌 82건

  1. MeshLab: an Open-Source Mesh Processing Tool Eurographics, Italian Chapter Conference · 2008 10.2312/localchapterevents/italchap/italianchapconf2008/129-136
  2. BigDataViewer: visualization and processing for large image data sets Nature Methods · Nature Portfolio · 2015 10.1038/nmeth.3392
  3. Developmental expression of <i>foxA</i> and <i>gata</i> genes during gut formation in the polychaete annelid, <i>Capitella</i> sp. I Evolution & Development · Wiley · 2008 10.1111/j.1525-142x.2007.00216.x
  4. U-Net: Convolutional Networks for Biomedical Image Segmentation Lecture notes in computer science · Springer Science+Business Media · 2015 10.1007/978-3-319-24574-4_28
  5. Matplotlib: A 2D Graphics Environment Computing in Science & Engineering · AIP Publishing · 2007 10.1109/mcse.2007.55
  6. Development of the annelid axochord: Insights into notochord evolution Science · American Association for the Advancement of Science · 2014 10.1126/science.1253396
  7. scikit-image: image processing in Python PeerJ · PeerJ, Inc. · 2014 10.7717/peerj.453
  8. The Visualization Toolkit: An Object-Oriented Approach to 3-D Graphics 1997
  9. Characterization of sarcoplasmic calcium binding protein (SCP) variants from freshwater crayfish Procambarus clarkii Comparative Biochemistry and Physiology Part B Biochemistry and Molecular Biology · Elsevier BV · 2011 10.1016/j.cbpb.2011.04.003
  10. Regeneration and endocrinology in the polychaetePlatynereis dumerilii Wilhelm Roux s Archives of Developmental Biology · Springer Nature · 1976 10.1007/bf00848884
  11. The evolution of cell types in animals: emerging principles from molecular studies Nature Reviews Genetics · Nature Portfolio · 2008 10.1038/nrg2416
  12. Fluorescent in situ hybridization reveals multiple expression domains for SpBrn1/2/4 and identifies a unique ectodermal cell type that co-expresses the ParaHox gene SpLox Gene Expression Patterns · Elsevier BV · 2009 10.1016/j.gep.2009.02.005
  13. The infracerebral gland in Nephtys—A possible neuroendocrine complex General and Comparative Endocrinology · Elsevier BV · 1970 10.1016/0016-6480(70)90013-4
  14. Further observations on the fine structure and development of the infracerebral complex (?infracerebral gland?) of Nereis limnicola (Annelida, Polychaeta) Cell and Tissue Research · Springer Science+Business Media · 1974 10.1007/bf00219671
  15. Scikit-learn: Machine Learning in Python arXiv (Cornell University) · Cornell University · 2012 10.48550/arxiv.1201.0490
  16. Rich Feature Hierarchies for Accurate Object Detection and Semantic Segmentation 2014 10.1109/cvpr.2014.81
  17. An intuitive framework for real-time freeform modeling ACM Transactions on Graphics · Association for Computing Machinery · 2004 10.1145/1015706.1015772
  18. Dimensionality Reduction by Learning an Invariant Mapping 2006 10.1109/cvpr.2006.100
  19. As-rigid-as-possible surface modeling 2007 10.5555/1281991.1282006
  20. ImageNet Classification with Deep Convolutional Neural Networks Neural Information Processing Systems · 2012
  21. Fiji: an open-source platform for biological-image analysis Nature Methods · Nature Portfolio · 2012 10.1038/nmeth.2019
  22. Regulatory tools and the characterization of insulinergic cells in the annelid Platynereis dumerilii 2013
  23. The evolutionary origin of bilaterian smooth and striated myocytes eLife · eLife Sciences Publications Ltd · 2016 10.7554/elife.19607
  24. The origin and evolution of cell types Nature Reviews Genetics · Nature Portfolio · 2016 10.1038/nrg.2016.127
  25. Neuronal cell-type classification: challenges, opportunities and the path forward Nature reviews. Neuroscience · Nature Portfolio · 2017 10.1038/nrn.2017.85
  26. Reconstructing cell cycle and disease progression using deep learning Nature Communications · Nature Portfolio · 2017 10.1038/s41467-017-00623-3
  27. Solving Large Multicut Problems for Connectomics via Domain Decomposition 2017 10.1109/iccvw.2017.7
  28. Weakly Supervised Learning of Single-Cell Feature Embeddings 2018 10.1109/cvpr.2018.00970
  29. Cell type transcriptome atlas for the planarian <i>Schmidtea mediterranea</i> Science · American Association for the Advancement of Science · 2018 10.1126/science.aaq1736
  30. Learning 3D Shape Completion Under Weak Supervision International Journal of Computer Vision · Springer Science+Business Media · 2018 10.1007/s11263-018-1126-y
  31. Cnidarian Cell Type Diversity and Regulation Revealed by Whole-Organism Single-Cell RNA-Seq Cell · Cell Press · 2018 10.1016/j.cell.2018.05.019
  32. Early metazoan cell type diversity and the evolution of multicellular gene regulation Nature Ecology & Evolution · Nature Portfolio · 2018 10.1038/s41559-018-0575-6
  33. Representation Learning with Contrastive Predictive Coding arXiv (Cornell University) · Cornell University · 2018
  34. Evolution of the bilaterian mouth and anus Nature Ecology & Evolution · Nature Portfolio · 2018 10.1038/s41559-018-0641-0
  35. UMAP: Uniform Manifold Approximation and Projection The Journal of Open Source Software · Open Journals · 2018 10.21105/joss.00861
  36. From Louvain to Leiden: guaranteeing well-connected communities Scientific Reports · Nature Portfolio · 2019 10.1038/s41598-019-41695-z
  37. U-Net: deep learning for cell counting, detection, and morphometry Nature Methods · Nature Portfolio · 2018 10.1038/s41592-018-0261-2
  38. Neuronal identity control by terminal selectors in worms, flies, and chordates Current Opinion in Neurobiology · Elsevier BV · 2019 10.1016/j.conb.2018.12.006
  39. Evolution of neuronal types and families Current Opinion in Neurobiology · Elsevier BV · 2019 10.1016/j.conb.2019.01.022
  40. Learning cellular morphology with neural networks Nature Communications · Nature Portfolio · 2019 10.1038/s41467-019-10836-3
  41. A Complete Electron Microscopy Volume of the Brain of Adult Drosophila melanogaster Cell · Cell Press · 2018 10.1016/j.cell.2018.06.019
  42. Capturing Single-Cell Phenotypic Variation via Unsupervised Representation Learning. PubMed · 2019
  43. Whole-animal connectomes of both Caenorhabditis elegans sexes Nature · Nature Portfolio · 2019 10.1038/s41586-019-1352-7
  44. Stem cell differentiation trajectories in <i>Hydra</i> resolved at single-cell resolution Science · American Association for the Advancement of Science · 2019 10.1126/science.aav9314
  45. Learning unsupervised feature representations for single cell microscopy images with paired cell inpainting PLoS Computational Biology · Public Library of Science · 2019 10.1371/journal.pcbi.1007348
  46. Robust and automated detection of subcellular morphological motifs in 3D microscopy images Nature Methods · Nature Portfolio · 2019 10.1038/s41592-019-0539-z
  47. Cell Type Classification and Unsupervised Morphological Phenotyping From Low-Resolution Images Using Deep Learning Scientific Reports · Nature Portfolio · 2019 10.1038/s41598-019-50010-9
  48. PRDM16 Maintains Homeostasis of the Intestinal Epithelium by Controlling Region-Specific Metabolism Cell stem cell · Elsevier BV · 2019 10.1016/j.stem.2019.08.017
  49. DeepGCNs: Can GCNs Go As Deep As CNNs? 2021 IEEE/CVF International Conference on Computer Vision (ICCV) · 2019 10.1109/iccv.2019.00936
  50. Image-derived models of cell organization changes during differentiation and drug treatments Molecular Biology of the Cell · American Society for Cell Biology · 2019 10.1091/mbc.e19-02-0080
  51. A Simple Framework for Contrastive Learning of Visual Representations arXiv (Cornell University) · Cornell University · 2020 10.48550/arxiv.2002.05709
  52. A connectome and analysis of the adult Drosophila central brain eLife · eLife Sciences Publications Ltd · 2020 10.7554/elife.57443
  53. Contrastive Multi-View Representation Learning on Graphs arXiv (Cornell University) · Cornell University · 2020 10.48550/arxiv.2006.05582
  54. Bootstrap your own latent: A new approach to self-supervised Learning arXiv (Cornell University) · Cornell University · 2020 10.48550/arxiv.2006.07733
  55. Momentum Contrast for Unsupervised Visual Representation Learning 2020 10.1109/cvpr42600.2020.00975
  56. Whole-animal connectome and cell-type complement of the three-segmented <i>Platynereis dumerilii</i> larva bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2020 10.1101/2020.08.21.260984
  57. Objective assessment of stored blood quality by deep learning Proceedings of the National Academy of Sciences · National Academy of Sciences · 2020 10.1073/pnas.2001227117
  58. Dense neuronal reconstruction through X-ray holographic nano-tomography Nature Neuroscience · Nature Portfolio · 2020 10.1038/s41593-020-0704-9
  59. Learning 3D Shape Completion Under Weak Supervision International Journal of Computer Vision · Springer Science+Business Media · 2018 10.1007/s11263-018-1126-y
  60. From Louvain to Leiden: guaranteeing well-connected communities Scientific Reports · Nature Portfolio · 2019 10.1038/s41598-019-41695-z
  61. Contrastive Multiview Coding Lecture notes in computer science · Springer Science+Business Media · 2020 10.1007/978-3-030-58621-8_45
  62. 3D FIB-SEM reconstruction of microtubule–organelle interaction in whole primary mouse β cells The Journal of Cell Biology · Rockefeller University Press · 2020 10.1083/jcb.202010039
  63. Globins in the marine annelid Platynereis dumerilii shed new light on hemoglobin evolution in bilaterians BMC Evolutionary Biology · Springer Science+Business Media · 2020 10.1186/s12862-020-01714-4
  64. A robust unsupervised machine-learning method to quantify the morphological heterogeneity of cells and nuclei Nature Protocols · Nature Portfolio · 2021 10.1038/s41596-020-00432-x
  65. Elementary nervous systems Philosophical Transactions of the Royal Society B Biological Sciences · Royal Society · 2021 10.1098/rstb.2020.0347
  66. Self-Supervised Deep Learning Encodes High-Resolution Features of Protein Subcellular Localization bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2021 10.1101/2021.03.29.437595
  67. seaborn: statistical data visualization The Journal of Open Source Software · Open Journals · 2021 10.21105/joss.03021
  68. Evolutionary cell type mapping with single-cell genomics Trends in Genetics · Elsevier BV · 2021 10.1016/j.tig.2021.04.008
  69. Functional connectomics spanning multiple areas of mouse visual cortex bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2021 10.1101/2021.07.28.454025
  70. Petascale neural circuit reconstruction: automated methods bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2021 10.1101/2021.08.04.455162
  71. Whole-body integration of gene expression and single-cell morphology Cell · Cell Press · 2021 10.1016/j.cell.2021.07.017
  72. Whole-cell organelle segmentation in volume electron microscopy Nature · Nature Portfolio · 2021 10.1038/s41586-021-03977-3
  73. Profiling cellular diversity in sponges informs animal cell type and nervous system evolution Science · American Association for the Advancement of Science · 2021 10.1126/science.abj2949
  74. Protein Organization with Manifold Exploration and Spectral Clustering bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2021 10.1101/2021.12.08.471858
  75. A surface morphometrics toolkit to quantify organellar membrane ultrastructure using cryo-electron tomography bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2022 10.1101/2022.01.23.477440
  76. Reconstruction of neocortex: Organelles, compartments, cells, circuits, and activity Cell · Cell Press · 2022 10.1016/j.cell.2022.01.023
  77. Marching cubes: A high resolution 3D surface construction algorithm ACM SIGGRAPH Computer Graphics · ACM SIGGRAPH · 1987 10.1145/37402.37422
  78. MoBIE: A Fiji plugin for sharing and exploration of multi-modal cloud-hosted big image data bioRxiv (Cold Spring Harbor Laboratory) · Cold Spring Harbor Laboratory · 2022 10.1101/2022.05.27.493763
  79. Self-supervised deep learning encodes high-resolution features of protein subcellular localization Nature Methods · Nature Portfolio · 2022 10.1038/s41592-022-01541-z
  80. PyTorch: An Imperative Style, High-Performance Deep Learning Library arXiv (Cornell University) · Cornell University · 2019 10.48550/arxiv.1912.01703
  81. MoBIE: a Fiji plugin for sharing and exploration of multi-modal cloud-hosted big image data Nature Methods · Nature Portfolio · 2023 10.1038/s41592-023-01776-4
  82. google/neuroglancer: Zenodo (CERN European Organization for Nuclear Research) · European Organization for Nuclear Research · 2021 10.5281/zenodo.5573294