Dimiter Prodanov1,2, Joost Heeroma3, and Enrico Marani1,2
1 Neuroregulation Group, Department of Neurosurgery, Leiden University Medical Center, University of Leiden, Leiden, The Netherlands
2 Biomedical Signals and Systems Group, Institute for Biomedical Technology, Twente University, Enschede, The Netherlands
3 Department of Neurogenomics, Center for Neurogenomics and Cognitive Research, Free University Medical Center, Amsterdam, The Netherlands
24 pages; 4 tables; 7 figures; 1 supplementary figure
Research article
Corresponding author: Dimiter Prodanov, Neuroregulation Group, Leiden University, PO Box 9604, NL-2300 RC Leiden, The Netherlands, fax: +31 71 527 6782, e-mail: dprodanov@excite.com
Numbers, linear density, and surface area of synaptic boutons can be important parameters in studies on synaptic plasticity in cultured neurons. We present a method for automatic identification and morphometry of boutons based on filtering of digital images using granulometric analysis. Cultures of cortical neurons (DIV8 and DIV21) were fixed and marked with fluorescently labeled antibodies for synapsin I (a marker for synaptic boutons) and MAP-2 (a marker for dendrites). Images were acquired on a confocal microscope and automatically processed. Granulometry, a morphological operator sensitive to the geometry and size of objects, was used to construct a filter passing fuzzy fluorescent grains of a certain size. Next, the filter was overlaid with the original image (masking) and the positive pixels were identified by an integral intensity threshold (thresholding). Disjoint grains, representing individual boutons, were reconstructed from the connected pixels above the threshold, numbered and their area was measured. In total, 1498 boutons with a mean diameter of 1.63 µm ± 0.49 µm (SD) were measured. Comparisons with manual counts showed that the proposed method was capable of identifying boutons in a systematic manner at the light microscopic level and was a viable alternative to manual bouton counting.
Key words: ImageJ; mathematical morphology; synapsin 1; MAP-2; cell culture
Studies of synaptic morphology can sometimes be greatly facilitated by the use of neuronal cell cultures (Boyer et al., 1998) . In cultures, synaptic boutons are arrayed in a thin layer at relatively low densities. This allows individual measurements to be performed more easily. In studies concerning synaptic plasticity in cell cultures, morphological parameters such as linear density and number of synapses, and size of the boutons can be particularly important (Tarsa and Goda, 2002 ; Palizvan et al., 2004) .
To establish the dose- or time- dependence of a specific pharmacological effect often a large number of different experimental groups are needed. This rapidly increases the number of individual samples to be evaluated. Because of the high variability of the localizations of synapses on dendrites and the clustering of boutons, the stereological assumption of homogeneity of spatial distribution is violated. Therefore, complete dendritic trees are counted. To facilitate counting in cell cultures we developed a reproducible and robust method for automatic identification and morphometry of synaptic boutons. The method was further applied to synaptic boutons marked for synapsin 1 immuno-fluoresecence from micro-island cultures of neocortical neurons.
Perhaps the oldest and most frequently used technique in the empirical sciences to quantify the size of solid particles is to use a series of sieves with increasing mesh openings. To quantify the properties of discrete sets of objects Matheron theorized empirical sieving into the formal concept of mathematical granulometry (Matheron, 1975) (see Appendix). Granulometry was later applied in image analysis to both binary and continuous tone images (Serra, 1982) . In a way similar to sieving grains, pixels comprising an image are “sieved” according to their connectivity to similar pixels imposed by a certain primitive geometric body termed Structuring Element (SE) (for illustration of the principle see Fig. 1). An integral characteristic of granulometry is the distribution of pixels with respect to the diameters of the used SE-s (Fig. 1). A local maximum in its normalized first derivative, the granulometric size density (G(d)), indicates the presence of a number of objects matching the particular SE. Moreover, granulometry can act as a band-pass filter capable of discriminating grains of a certain size based on their similarity to a SE (Dougherty and Chen, 2001) . By exploiting this property, images can be simplified substantially to successfully isolate various classes of objects (Fig. 1).
Fig. 1: Granulometry of a binary image
An image containing 3 disks with diameters 10, 16 and 26 pixels is presented (noted “Original”). During granulometry, the image is successively sieved with a family of homothetic disk SE-s of increasing diameters d. Each sieving step that removes a disk from the image results in a local maximum in G(d). Derived images corresponding to the G(d) maxima - I10, I16, and I26 - are depicted together with the used SE-s - SE10 (d=10), SE16 (d=16) and SE26 (d=26). By subtracting derived images, it is possible to isolate individual disks.

The algorithm employed in the study can be outlined in the following main steps:
1) Perform granulometry of the image and compute G(d) (Appendix, eq. VIII).
2)
Identify the scale of interest by the pattern
of the peaks in G(d); select low bound
and
high bound images
, where
“o” denotes the opening operation (Appendix eq. III), and subtract the images.
3) Construct the binary “mask” using the k-means clustering algorithm (Jain and Dubes, 1988) - a method that can overcome background autofluorescence of the studied cell structures more easily (see Discussion).
4) Delete irrelevant structures by superimposing the mask on the original image using bit-plane logical AND operation (masking). Threshold the resulting image using the integral thresholding (Appendix, eq. IX ) - a method that can reduce the variation in the area measurements (see Discussion).
5) Construct disjoint grains from the pixels that are above the threshold based on their 8-connected neighborhoods as implemented in ImageJ.
6) Enumerate and measure the grains constructed in this way.
Micro island cortical cultures were prepared from embryonic day 18 murine embryos (Heeroma et al., 2004) . Neuronal cells were harvested on the 8th day (DIV8) and on the 21st day (DIV 21) of in vitro culturing (densities approx. 6000 neurons/cm2). Cultures were stained with antibodies against a marker for dendrites, microtubule-associated protein 2 (MAP-2) (Six et al., 1992) , and a marker for synaptic vesicles, synapsin I (Huttner et al., 1983) . Cultures were fixed by 4% paraformaldehyde, washed 2 times for 15 min with PBS, and incubated in 0.1% Triton X-100 for 5 minutes followed by 4% fetal calf serum for 20 minutes. After washing with PBS, cultures were incubated for 1 hour at room temperature in a mixture containing 0.1% Triton X-100, mouse monoclonal anti-MAP-2, 1/200 (Boehringer, Alkmaar, The Netherlands) and rabbit polyclonal anti-synapsin I, 1/1000 (clone E028; Heeroma et al., 2004 ) antibodies diluted in PBS. After washing 3 times with PBS, the cells were incubated for 1 hour at room temperature in secondary antibodies conjugated to anti-rabbit-Cy5 or anti-mouse-Alexa546 (Molecular Probes, Oregon, USA) (Heeroma et al., 2004) . Finally, the slides were washed in PBS and cover-slipped with Dabco-Mowiol (Heimer and Taylor, 1974) .
Cultures were analyzed on a Zeiss 510 Meta confocal microscope (Carl Zeiss, Heidelberg, Germany). A set of 57 high-resolution digital images of different cultures was recorded at a resolution of 4.45 pixels per µm. Images were acquired on 2 channels – cyan, comprising anti-synapsin staining and red, comprising anti-MAP-2 staining. In order to reduce the amount of debris, all but the area situated within 3 µm distance of any MAP-2 positive dendritic branches was blanked in the images.
Image processing and measurement steps were performed in the public domain software for image analysis ImageJ (NIH, Bethesda, Maryland, USA; http://rsb.info.nih.gov/ij/). The algorithm was run on the synapsin channel of every image. The identified boutons were numbered and their areas, equivalent diameters, and planar co-ordinates were measured and recorded. The derived images containing markings of detected objects were printed.
Two experimental trials involving observers experienced in morphometry were performed: a “free” count trial and a “calibrated” count trial. During the “free” count trial, the observers had to mark each bouton they could identify in the images according to a size criterion (see Results). During the “calibrated” count trial, to reduce the variability coming from the “nature” of the observers (i.e. disagreement due to preferences to lower or higher counts) and to increase the statistical power, as an additional constraint, the expected number of boutons per image was preset to the number counted by the algorithm (i.e. “tea tasting lady experiment” design; Fisher, 1935 ).
To quantify the differences in identification of objects the notions of “method-observer disagreement” and “inter-observer disagreement” were used (see Table I for the formulae). This was necessary due to the absence of a “reference standard” method, a frequent situation in automated image analysis studies in the biological sciences. The synapsin channels of a representative set of images (n=9) were printed in continuous grey tone and divided in quadrants. The prints were presented independently to two observers to identify, mark, and count boutons. To evaluate the disagreement measures, objects marked either by the automatic procedure or by the human observers were matched and their counts were recorded per quadrant (see Table I). To determine inter-trial disagreements, manually counted printouts in the trials were compared to each other by the same procedure.
Table I: Parameters and comparisons used in the validation studies
| Algorithm → Na |
Observer 1 → N1 |
Observer 2 → N2 |
|
| Algorithm |
- |
Mm1 |
Mm2 |
| Observer 1 |
|
- |
Mo |
| Observer 2 |
|
|
- |
N1 – number of objects detected by Observer 1; N2 - number of objects detected by Observer 2; Na - number of objects detected by the algorithm; Mm – number of matched objects between an observer and the method; Dm – method observer disagreement; Mo – number of matched objects between Observer 1 and Observer 2, Do- inter-observer disagreement.
Data were analyzed statistically by means of Student’s, Chi-square, and Kolmogorov-Smirnow’s t-tests, regression analysis, and analysis of variance (ANOVA) including post hoc comparisons by Scheffe, Neuman-Keuls, and LSD tests. Probability levels of less than 0.05 were considered significant.
The working of the algorithm is illustrated in Fig. 2. A synthetic image (Fig. 2A) was produced by painting randomly located circles using different brush sizes and varying degrees of fuzziness. Granulometry was performed with flat disk-shaped SE-s. G(d) showed pronounced maxima that matched the brush diameters used for the drawing at d=4, 7, 10, and 13 pixels (Fig. 2D). The filtering procedure is exemplified further for the marked peak (Fig. 2D, asterisk). A total of 66 grains comprising 3.6% of the image area was identified (orange, Fig. 2C).
Fig. 2: Granulometric filtering procedure of a synthetic image
A – Synthetic image with dimensions 200 x 200 pixels containing 5 types of bright grains of varying grades of fuzziness. B - the mask derived from the marked peak in G(d) (asterisk, D). C – Co-localization of the mask (red) and the original image (green). Co-localized grains appear in orange color. D - Smoothed G(d) of the synthetic image (A).

As the fluorescent patches were round, granulometry was performed with a family of flat disk-shaped SE-s ranging from d=1 to d=25 (0.2 μm - 5.6 μm). A consistent pattern could be discerned in the shape of the averaged G(d) (Fig. 3) – a peak region (P) in the range 0.7 – 1.6 μm, an intermediate region (shoulder - S) in the range 2.0 μm – 2.5 μm, and a decreasing region (tail - T) - from 2.9 μm on. The discerned regions were significantly different from each other (p<0.0001, univariate ANOVA). Post hoc comparisons of the means showed significant differences by all tests (p<0.0001). The P-region was larger than the tail (Fig. 3; asterisks, P) and the S-region (Fig. 3; double asterisks, P). The S-region was larger than the tail (Fig. 3; asterisks, S), but not larger than the origin. The tail was smaller than the origin.
The P-region corresponded to the presence of a large number of synapsin positive grains of matching sizes. The diameter range of these conformed to the size range of synaptic boutons described previously (Alsina et al., 2001) . Accordingly, for the construction of Ilow values of either dlow=3 or dlow=5 were selected depending on the individual G(d) and the amount of debris in an image. To construct Ihigh, the S-region was considered as well because in some images larger synaptic boutons were noticed. Accordingly, dhigh=11 was selected as a parameter for Ihigh. An example is given in Fig. 4D.
Based on the discrimination of dark background, auto-fluorescing cell mass, and synapsin positive grains three brightness classes were used during k-means clustering. The brightest class was selected for the construction of the mask (Fig. 4E). During the integral thresholding, sufficient overlap of the thresholded particles with the actual synapsin grains was typically achieved for AF=0.8 (Area factor, see Appendix). An example outcome of the detection procedure is presented in Fig. 4F.
Fig. 3: Averaged granulometric size density distribution of the entire image set
For descriptive purpose, we discerned peak (P), shoulder (S), and tail (T) regions (see text). Data are presented as means and confidence intervals.

Fig. 4: Illustration of the granulometric filtering technique on a real image
A – High-resolution image of synapsin I staining; B – MAP-2 staining; C – Co-localization of synapsin I (cyan) and MAP-2 (red); D – inverted filtered image, step 2 of the algorithm. E – mask image, step 3; F – co-localization of the detected synaptic boutons (red outline) with the original synapsin I image. Scale bar – 5 µm.

Table II: Descriptive statistics of the measured boutons
| Mean |
Median |
Mode |
P5% |
P95% |
SD |
Skew |
Kurtosis |
|
| Area [μm2] |
2.28 |
1.92 |
0.91 |
0.71 |
5.19 |
1.41 |
1.29 |
1.47 |
| Diameter [μm] |
1.63 |
1.56 |
1.075 |
0.95 |
2.57 |
0.49 |
0.66 |
-0.06 |
P5% - 5th percentile, P95% - 95th percentile, SD - standard deviation.
Measurements of the cultured cells are reported solely to illustrate the suitability of the method (Table II). In total, 1498 boutons were automatically detected and measured in 57 images; 90% of them had diameters between 0.95 and 2.57 µm. Therefore, a simple size criterion for the manual validation could be formulated – boutons were defined as sharp synapsin-positive grains having diameters between 1 and 2.6 µm.
The free count trial was performed on 451 quadrants (n=9 images, 422 µm2 per quadrant on average). Summary of the trial is given in Table III. The method-observer and the inter-observer disagreements did not differ significantly (Table III; paired t-test, all comparisons gave p>0.05). Observer 1 (O1), Observer 2 (O2), and the algorithm (A) identified the same mean number of synapses (paired t-test, in all comparisons p>0.30). The counts correlated strongly among each other (A and O1 – r=0.99, A and O2 – r=0.96, O1 and O2 – r=0.95; r denotes Pearson’s correlation coefficient).
An important finding was the correlation between the number of mismatching objects of each observer and the number of objects counted by the algorithm in the same image (A and O1 – r=0.69, A and O2 – r=0.71). By using the “automatic” number as denominator in the disagreement measure, we compensated for this effect in the statistical analysis. Based on this correlation, only the images with similar density of synapsin-positive grains were selected for the calibrated count trial.
Table III: Matched synapses and disagreements – free trial
| Algorithm |
Observer 1 |
Observer 2 |
|
| Algorithm |
- |
Mm1=10.33 ± 11.19 |
Mm2=12.67 ± 13.06 |
| Observer 1 |
Dm1=47.21% ± 15.58% |
- |
Mo=9.50 ± 6.39 |
| Observer 2 |
Dm2=30.62% ± 17.28% |
Do=56.12% ± 31.60% |
- |
In the calibrated count trial, 77 objects in 348 quadrants (n=7 images; 380.12 µm2 per quadrant on average) were counted (summary in Table IV). In total, 44 quadrants containing synaptic boutons were marked by either of the observers. The inter-observer and the method-observer disagreements did not differ significantly (Table IV; paired t-test, in all comparisons p>0.40). The mean number of matched boutons per observer did not differ significantly from the expected number of boutons (Table IV; Chi-square test).
Further, we examined the origins of the encountered method-observer disagreement. In 81.82% of the quadrants, there was a complete agreement between Observer 1, Observer 2 and the algorithm; in 4.55% of the quadrants, boutons identified by the observers were not present in the mask image. In 13.64% of the quadrants, the method-observer disagreement was due to the setting of the AF value.
Table IV: Matched synapses and disagreements – calibrated trial
| Algorithm |
Observer 1 |
Observer 2 |
|
| Algorithm |
- |
Mm1= 8.14 ± 2.79, p= 0.42 (Chi-square) |
Mm2= 8.00 ± 2.77, p= 0.29 (Chi-square) |
| Observer 1 |
Dm1= 21.73% ± 13.08% |
- |
Mo= 8.86 ± 3.09 |
| Observer 2 |
Dm2=22.57% ± 16.45% |
Do=15.48% ± 10.45% |
- |
Data are presented per image as mean ± standard deviation (see Table I for the notations).
The inter-trial disagreement for Observer 1 was 31.90% ± 15.92% and for Observer 2 was 13.66% ± 6.37% compared for the same images. During the calibrated count trial, the averaged inter-observer disagreement was lowered 2.4 times and the method-observer disagreement was lowered 2.2 times compared to the free count trial.
Unexpectedly, the bouton counts per image at DIV8 (21.92 ± 26.41) were not significantly different from the bouton counts at DIV21 (31.24 ± 27.52) (p>0.05, t-test). Bouton diameters were distributed uni-modally at both DIV8 and DIV21 (Fig. 5). The mean bouton area and the mean bouton diameter were larger at DIV21 (area 2.35 ± 1.47 μm2; diameter 1.65 ± 0.51 μm; n=906) than at DIV8 (area 2.18 ± 1.31 μm2; diameter 1.60 ± 0.47 μm; n=592)(p<0.05; t-test). However, the distributions did not differ in shape (p>0.05; Kolmogorov-Smirnow test). Days in vitro had a statistically significant influence on G(d) (ANOVA, p<0.0001).
Fig. 5: Effect on DIV on the size distribution of the synaptic boutons

Sensitivity of the automatic bouton identification and measurements to parameter variation
The variation in the numbers and the area of the automatically identified synaptic boutons, caused by the choice of parameter settings, was studied in the set of images used for the manual verification (n=9).
To study the influence of the area factor parameter, the original granulometric filter settings were retained while the AF value was varied and the numbers and areas of the boutons were measured. As expected, both the numbers and the areas of the synaptic boutons depended on AF (Fig. 6 A and B). The mean bouton area (MA) varied linearly with AF (Fig. 6A) and obeyed the regression equation MA=3.09AF-0.11 (R2=0.995; beta=0.998; p<0.0001). In contrast, the mean number of boutons varied non-linearly with AF and reached saturation for values exceeding 0.4 (Fig. 6B).
The bandwidth settings used to count the image set (dlow=5, dhigh=11), denoted as “original”, were selected on the basis of literature data for the sizes of the synaptic boutons (Alsina et al., 2001) . To study the influence of the granulometric filter bandwidth on the number of identified boutons, the algorithm was rerun using several different bandwidths: broader bandwidth (dlow=3, dhigh=15), denoted “broad”; narrower bandwidth (dlow=5, dhigh=9), denoted “narrow”; and shifted bandwidth (dlow=7, dhigh=13), denoted “shifted” (Fig. 7). The AF was kept fixed to 0.8. In Fig. 7, the relative count differences (RD, see legend) are depicted against the “original” bandwidth counts (baseline). Broad bandwidth counts were higher than narrow bandwidth counts (p<0.05; paired t-test; Fig. 7, asterisk) and shifted bandwidth counts (p<0.001; paired t-test; Fig. 7, double asterisks). There were no differences with the observer counts (all comparisons p>0.21; paired t-test; Fig. 7). As expected, the narrow bandwidth counts were lower than the original and the broad bandwidth counts were higher than the original (0 was not in the 95% confidence interval of RD for either of them). The shifted bandwidth counts were marginally different from the original (0 was not in the 90% confidence interval of RD).
Fig. 6: Sensitivity of the automatic area measurements and the counts to the variation of AF
The mean bouton area (A) varied linearly (dashed line) with AF while the mean number of boutons (B) rapidly reached saturation.

Fig. 7: Sensitivity of the automatic counts to the variation of filtering bandwidth
Relative differences - RDi=1-Ni/Noriginal; i denotes either of “broad”, “narrow”, or “shifted” bandwidth counts, or the averaged observer counts in the free count trial (“manual”); Noriginal denotes the “original” bandwidth (dlow=5, dhigh=11) counts. Observer counts have the largest variation. Data are presented as means and confidence intervals.

Until now, analysis of images by granulometry was applied to the detection of fluorescent signals in “in situ” hybridization (Grigoryan et al., 2002) , DNA micro-arrays (Angulo and Serra, 2003) , and to the counting of blood cells (Di Ruberto et al., 2002) , and parasites (Theera-Umpon et al., 2001) . By means of similar granulometric analysis and filtering, we could successfully identify and perform measurements on synaptic boutons using specific immuno-fluorescence (Fig. 3).
The most common approach in automatic image analysis for identification of objects in a gray level image is to threshold the image and then to identify the objects based on a priori information of their size and shape. This approach has potentially two shortcomings. First, in fluorescence microscopy, the uneven illumination of the total field can result in a global intensity gradient across the acquired digital image caused by the emission of the mounting medium. If such an intensity gradient possesses intensity comparable to the objects of interest, a global threshold will introduce a bias towards the lighter intensities. Eventually, fusing of objects and overestimation of their area can occur. In contrast, an algorithm based on granulometry will have an advantage because intensity gradients may affect G(d) only at very large scales and therefore will not interfere with the extraction of small objects. Second, if digital particles are classified by the circularity of their shapes, values exceeding the theoretical bonds for perfect continuous circles (i.e. larger than one) can be calculated for the small grains consisting of several pixels. This is caused by the digitization sampling resulting in underestimation of the particle perimeter, i.e. the pixel is an elementary measure of area and not of length. Therefore, the small digital particles will be misclassified resulting in bias in the identification procedure.
We used thresholding steps in two stages of the proposed algorithm.
After the granulometric filtering of the original image, in step 3, the k-means
clustering was used. This algorithm divides the image histogram in multiple
classes of pixels that potentially discriminate between different objects
(Jain and Dubes, 1988) . The choice of multilevel thresholding was supported by the presence
of cell structures having varying degrees of autofluorescence intermingled
with the actual synapsin 1 signal. Such structures were not completely removed
by the granulometric filter (Fig. 4A and D). The automatic thresholding, based
on iterative sub-histogram average intensity decomposition as implemented
in ImageJ (http://rsb.info.nih.gov/ij/docs/faqs.html),
did not identify correctly the synaptic boutons in some of the filtered images.
This was due to the overlapping distribution of the foreground pixels and
the background gray levels as discussed in literature (Sezgin
and Sankur, 2004) .
In step 4 of the algorithm, an integral thresholding approach was used. By fixing AF, the estimate of the synaptic bouton area can be controlled (Fig. 6A) assuming the same conditions for image acquisition (i.e. same microscope optics, magnification, and camera). Moreover, values of AF greater than 0.4 did not affect the mean number of identified buttons (Fig. 6B).
In both trials, human observers identified the same objects as the algorithm did (Tables III and IV). The method-observer disagreements indicated that the algorithm performed equally to a human observer. An unexpected finding in the “free” trial was the magnitude of the inter-observer disagreement. Presetting the expected outcome of identification (i.e. number of boutons to be detected by observers) reduced the inter-observer disagreement 2.4 times in the “calibrated” trial.
Manual counts of anatomical structures can be tedious and error-prone, and result in a very long processing time (Benali et al., 2003) . As demonstrated also in our study by the observed inter-trial disagreement, even experienced observers do not count exactly the same number of objects if the same picture is presented several times. In contrast, a deterministic algorithm will always count the same number of objects with the same parameter settings and is therefore preferable (Geuna et al., 2001 ; Benali et al., 2003) .
Within presynaptic terminals, synapsin I is concentrated in the compartment occupied by the synaptic vesicles (Sudhof et al., 1989 ; Fletcher et al., 1991) . It is considered an excellent marker for the synaptic terminal and is used routinely to estimate synaptic density (De Camilli et al., 1983 ; Moore and Bernstein, 1989 ; Fletcher et al., 1991) . Due to the prohibitive time expenditure of electron microscopic morphometry, a number of studies were performed to correlate light microscopic measurements of synaptic structures to electron microscopic measurements (Papa et al., 1995 ; Boyer et al., 1998 ; Harata et al., 2001) . It was found that the area occupied by synaptic vesicles loaded with fluorescent dye corresponded to the dimensions of the bouton on electron microscopic level (Harata et al., 2001) . Therefore, we can correlate the area of the synapsin positive grain (i.e. the total projection area of the synaptic vesicles) to the area of the synaptic bouton. Reported subtle differences in the mean bouton area (i.e. four times smaller than the resolution of the image) and in the shape of G(d) at DIV8 and DIV28 that do not reflect in corresponding differences in the bouton area histogram shapes probably correspond to slight differences either in the image acquisition conditions or in the performance of the immuno-cytochemical procedures.
An advantage of the proposed automated approach is that, apart from the number of synaptic boutons in a light microscopic image, it also allows to be measured morphological characteristics such as area, circularity, and maximal diameter. The proposed approach is not restricted solely to bouton detection. At different scales and using suitable labeling other cell structures such as nuclei or axonal profiles can also be identified and measured.
D.P. was funded by a European Commission grant as part of the Research and Training Network NeuralPRO (Framework 5, contract No HPRN-CT-2000-00030 - Neural Prostheses). The authors would like to acknowledge W.S. Rasband from the National Institutes of Health, Bethesda, Maryland, USA for his continuous development and support of ImageJ.
Mathematical morphology offers tools for
analysis and processing of images based on the key set theory operations inclusion
(
),
union (
) and
intersection (
)
(Serra, 1982) . Grey level images and SE-s can be represented by 3D functions
with their elevation indicating intensity (Sternberg, 1986) . The associated
sets are then the geometric bodies bellow the functions – so called “umbras”.
Principal operations in mathematical morphology are erosion, dilation, opening
and closing. If S(x) is the umbra of the image S and
E(x) is a SE set, erosion and dilation are defined by
(I)
(II)
Opening of S by E is defined as
(III)
and closing of S by E as
(IV)
Mathematically, granulometry is
defined as a parameterised family of openings or closings characterized by
the scale parameter d (Matheron, 1975)
. In the case of a homothetic family of SE-s,
granulometry can be represented by:
. (V)
In the formula,
d is the proportionality parameter of the homothety. By
convention
and
for negative d opening is replaced by closing. For greyscale
images, the measure of the interaction with SE is the volume V[] removed by
sieving. Its mapping onto the scale axis d is called granulometric
size distribution:
W(d)=V[S]-V[
] (VI)
The granulometric size density is
the normalized generalized derivative of W(d):
(VII)
The volume of image can be estimated
from its histogram H by
and
the granulometric size density by
. (VIII)
Gray-level morphological operations erosion, dilation, opening and closing were implemented as a sub-routine in ImageJ (http://rsb.info.nih.gov/ij/plugins/gray-morphology.html).
To produce binary particles we introduce a parameterized integral threshold operator TrAF (T-min, T-max) depending on the area factor parameter AF. TrAF (T-min, T-max) labels a pixel in the image if its intensity g falls between lower (T-min) and upper threshold (T-max) bounds constrained by the condition that the ratio between the area of the labeled pixels and the area of the non-black pixels equals AF:
(IX)
In the formula, A[] denotes the area operator acting on the whole image. For the aims of the study, T-max was set to 255 while T-min was determined by varying its value until the condition was globally satisfied. The behavior of the threshold operator was studied in several simulated images having varying amounts of gaussian noise specified by its standard deviation (50, 100, 150, and 200; Supp. Fig. 1). The functional relationship between AF and T-min in the synthetic images is depicted in Supp. Fig. 1.
Supp. Fig. 1: Dependence of the AF on the pixel intensity in synthetic images
AF is plotted versus T-min for 5 synthetic images – the image from Fig. 2A (denoted as “star”), and simulated images (dimensions 200 x 200) containing varying amounts of gaussian noise (σ=50, 100, 150 and 200) denoted as “noise σ” in the legend.
