Automated quantification of synaptic boutons reveals their 3 D distribution in the insect 1 mushroom body 2 3

Synaptic boutons are highly plastic structures undergoing experience-dependent changes in their number, volume, and shape. Their plasticity has been intensively studied in the insect mushroom bodies by manually counting the number of boutons in small regions of interest and extrapolating this number to the volume of the mushroom body neuropil. Here we extend this analysis to the synaptic bouton distribution within a larger subregion of the mushroom body olfactory neuropil of honey bees (Apis mellifera). This required the development of an automated method combining two-photon imaging with advanced image post-processing and multiple threshold segmentation. The method was first validated in subregions of the mushroom body olfactory and visual neuropils. Further analyses in the olfactory neuropil suggested that previous studies overestimated the number of synaptic boutons. As a reason for that, we identified boundaries effects in the small volume samples. The application of the automated analysis to larger volumes of the mushroom body olfactory neuropil revealed a corrected average density of synaptic boutons and, for the first time, their 3D spatial distribution. This distribution exhibited a considerable heterogeneity. This additional information on the synaptic bouton distribution provides the basis for future studies on brain development, symmetry, and plasticity.


Introduction
small ROIs to estimate an overall average density 22 . Due to the absence of an efficient automated 48 analysis of larger ROIs, information about the spatial distribution of microglomeruli within the MB 49 calyx has been missing. 50 A few automated methods have been suggested but were either applied to small ROIs 23 only, or their 51 performance has been seriously questioned 24,25 because the absolute numbers of microglomeruli they 52 provided strongly deviated from previously reported ones. An obvious limitation of automated counting 53 is the vicinity of microglomeruli within the MBs, which is at the resolution limit of those microscope 54 objectives that would allow imaging larger regions of the MBs. Moreover, the heterogeneity of 55 fluorescent dye distribution after immunohistochemical staining of whole-mounted brains prevents 56 simple standard segmentation algorithms to obtain accurate counting results.

Consistent number of microglomeruli obtained with the automated counting in ROIs 69
A major obstacle to the development of automated methods quantifying microglomeruli numbers has 70 been the high vicinity of microglomeruli within the MB neuropil. Besides increasing the z-resolution by 71 two-photon microscopy 26 , the most important improvement in separability of microglomeruli in the 72 present study was obtained by applying a 3D deconvolution to the raw data using the precisely measured 73 point spread function of the microscope (Fig. 1). The resulting resolution of the lip images was sufficient 74 to apply an automated analysis of microglomerular number using multiple thresholds segmentation. The automated method gave a number of microglomeruli comparable to the one obtained by manual 87 counting in 1000 µm 3 cubic ROIs within the MB lip (Fig. 2). A statistical analysis did not show a 88 significant difference between the two methods (paired t-test; t = -1.34, p = 0.22, n = 10). This is the 89 first validation of an automated method for the quantification of microglomerular numbers by direct 90 comparison with the established manual method. The results obtained with the automated method were also consistent with the values obtained in the 103 literature by manual counting in bees of similar age (Table 1). This was not the case of previously 104 suggested automated methods 24,27 . Peng and Yang 24 obtained values 18-fold lower than the ones 105 obtained by manual counting in 1000 µm 3 ROIs (Table 1). This may have been due to improper 106 segmentation methods and the insufficient depth resolution of 5 µm between slices 25 . Indeed since the 107 diameter of microglomeruli ranges on average 18 from 2.5 µm 3 to 4 µm 3 , their coarse depth sampling 108 may have overlooked several boutons. Also, the resolution limit of confocal microscopes along the z-109 axis falls in that range, which might have caused failure to separate neighboring microglomeruli. A limit 110 that was overcome by our advanced post-acquisition processing of the MB lip images (Fig. 1)  Previous manual methods considered a linear relationship between the number of microglomeruli and 123 the volume of the ROIs in which they were counted. It became a standard to extrapolate measurements 124 from the 1000 µm 3 ROIs to the volume of the whole MB subregion 18 . The problem of this procedure is 125 the inclusion of microglomeruli whose centers fall inside the ROI but not their entire volume. What 126 seems a negligible inaccuracy, sums up to a significant error during the extrapolation. This error could 127 be quantified by applying the automated method to increasing ROI volumes (Fig. 3A). The number of 128 microglomeruli showed a drastic deviation from a linear scaling with volume. A boundary-corrected 129 model, which assumes that the number of microglomeruli cut by the ROI boundaries scales with the 130 surface area of the ROIs (see Materials and methods), fitted the data nicely. Furthermore, it shows that 131 the automated counting applied to a lip subregion (40 µm depth) agrees precisely with the predicted 132 number from the boundary-corrected model (Fig. 3A inset). It proves that the high accuracy of 133 automated counting is conserved also for large volumes, where a comparison with manual counting is 134 This allowed for a corrected estimation of the number of microglomeruli in the whole lip, showing that 136 a linear extrapolation of numbers obtained in 1000 µm 3 ROIs overestimated the correct number on 137 average by 100% (Fig. 3B) (significant by Wilcoxon test; W = 55, p < 0.005, n = 10). This overestimation 138 must be assumed for all the previously reported values obtained with the standard manual counting 139 method in 1000 µm 3 ROIs. Table 1 provides an overview of the corresponding studies. For bees with an 140 age equivalent to the ones used by us (10 days), manual counting indeed reported a considerably higher 141 number of microglomeruli in the whole lip although the values in 1000 µm 3 ROIs were slightly smaller 142 (Table 1, highlighted lines). The number of microglomeruli in the lip has been shown to decrease in 143 older bees due to the synaptic pruning associated with foraging onset 17,19 . Yet, the number of 144 microglomeruli reported in the whole lip of old foraging bees was similar to the one obtained in the 145 present study in 10-day-old bees, while it was lower in 1000 µm 3 ROIs. 146 To avoid an overestimation of the density when counting in small ROIs, boutons that are partially 147 outside the ROI should be counted only as fractions of one, corresponding to the percentage of their 148 volume that lies inside the ROI. This significantly complicates and decelerates the already slow 149 procedure and is another strong argument for automated counting over larger volumes. 150 The boundary effect became negligible for larger volumes (>10 5 µm 3 ) (Fig. 3A). It is therefore not 151 required to determine the boundary-corrected fitting function, but a linear extrapolation of the number 152 of microglomeruli in these volumes to the whole lip produces neglectable deviations with respect to 153 variation across animals (t-test; t = 0.64, p = 0.53, n = 10) ( Supplementary Fig. S1). This result confirms 154 that applying the automated method to a subregion of 40 µm depth is sufficient to estimate efficiently 155 the absolute number of microglomeruli in the whole lip. Advanced image processing, based on 3D deconvolution, strongly improved the quality of our images 176 acquired with a 20× objective (Fig. 1). This allowed avoiding the use of high magnification objectives, 177 which are not suitable for an analysis of large volumes of the MB due to their small working distance 178 and the small field of view. Thanks to the extended volume data, we were able to analyze for the first 179 time the spatial distribution of microglomeruli in a subregion of the MB lip (Fig. 4A) and to measure 180 their local density (Fig. 4B-D). The data revealed a substantial heterogeneity of the microglomerular 181 When smaller structures need to be described (e.g. individual synapses), higher resolution and higher 198 magnifications are required. Until now, this has mainly been achieved using electron microscopy 8,29-31 . 199 However, new advances in light microscopy, in particular, the development of nanometer-resolution microscopes, will allow for future optical studies down to the synaptic level 32 . Still, the described 201 problem of boundary effects, being a general phenomenon, will be relevant also for those applications. 202 Even in completely different scenarios, whenever objects of an extended size are counted within small 203 sample volumes, a linear extrapolation of these counts should be examined critically for potential biases 204 from boundary effects, as reported in this study.

Animals 219
Experiments were performed in June 2018 on a honey bee colony (Apis mellifera) maintained at the 220 University of Trento in Rovereto. Inter-individual variability in brain structure was reduced by using 221 same-age honey bees reared under controlled conditions. For this, a comb of brood about to emerge was 222 taken from the hive and left in complete darkness in an incubator (34°C, 55% humidity) overnight. 223 Newborn adult bees were collected in the following morning. They were placed in cages (8×5×4.5 cm, 224 15 bees per cage) in complete darkness in an incubator (34°C, 55% humidity) for 7 days with unlimited 225 access to sucrose solution (50% w/w) and water. The sucrose solution and water were changed every 226 two days. 227 228

Immunostaining of synapsin in whole-mount brains 229
The protocol used for the immunostainings is fully described in elsewhere 18 . The brains of 7-day-old To improve contrast and resolution of the image stacks, essential for robust discrimination of 259 microglomeruli, images of the lip subregion were post-processed by a 3D deconvolution in AMIRA. 260 The required Point Spread Function (PSF) of the microscope objective was measured using fluorescent 261 beats (TetraSpeck, 0.1 µm, Thermo Fisher). The maximum-likelihood deconvolution algorithms 262 required 100 iterations for sufficient convergence. Images were then resampled to a final voxel size of 263 0.1×0.1×0.1 µm (Fig. 1). 264 265

Quantification of microglomeruli 266
The manual and automatic methods for microglomerular quantification were first applied to ROIs of 267 size 10×10×10 µm, positioned within the lip (Fig. 1B). 268 Manual counting was performed using the AMIRA LandmarkEditor by placing landmarks on visually 269 identified microglomeruli (Fig. 5C). 270 The automated counting protocol was based on the idea that repeated image segmentation using varying 271 threshold levels assures that all separate objects are extracted from the image at least once. They were 272 counted exactly once, by removing objects of identical position. In details, the AMIRA 273 SegmentationEditor was used to label voxels whose signal intensity was above a certain threshold. The 274 threshold was varied in repeated applications from 20% to 90% of the maximum image intensity in steps 275 of 10% (Fig. 5A, B). Connected labeled voxels formed objects whose center coordinates and volumes 276 were extracted using the RegionStatistics module and exported in XML-format for further analyses.

Quantification of boundary effects when counting in ROIs 303
When counting microglomeruli in cubic ROIs, some microglomeruli are inevitably located at the 304 boundaries of the ROIs. To evaluate the influence of boundary effects, ROIs of different volumes: 1000 305 µm 3 (10×10×10 µm), 3375 µm 3 (15×15×15 µm), and 8000 µm 3 (20×20×20 µm) were selected around 306 the same center point. The included microglomeruli were counted with the automated method. 307 Microglomerular numbers were averaged over different bees and their scaling as a function of ROI 308 volume was analyzed by fitting two models. 309 A first model assumed that boundary effects were negligible and extrapolated the number of 310 microglomeruli in the 1000-µm 3 ROI linearly with the volume: 311 (1) 312 A second model assumed that besides the number of microglomeruli entirely included in the ROI, which 313 increases linearly with the ROI volume, there was an additional contribution of the microglomeruli 314 partially cut by the ROI boundaries. These microglomeruli constitute a share proportional to the 315 boundary area. Since the boundary surface area scales with the volume as 2/3 , the fitting function 316 reads: 317 2 ( ) = + 2/3 (2) 318 This boundary effect will lose importance with increasing V, showing a linear scaling for high V. 319 Comparing the real data to the two models allowed to evaluate whether the data actually deviated from 320 the linear behavior and if so, to identify the ROI volume from which boundary effects became negligible. 321 322

Statistical analyses 323
The normality of data distribution was confirmed for all variables by applying a Shapiro-Wilk test (p > 324 0.05). The homogeneity of variances was assessed with a Bartlett test. Since both normality and 325 homoscedasticity were verified, a paired t-test was used to compare the number of microglomeruli 326 counted with the manual and automated methods in the ROIs of 1000 µm 3 . Since variances between 327 microglomerular numbers estimated in the whole lip by the two models were heterogeneous, a Wilcoxon 328 test was used to compare these numbers. 329 330 331