Stochastic Distance Transform

  • Johan ÖfverstedtEmail author
  • Joakim Lindblad
  • Nataša Sladoje
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 11414)


The distance transform (DT) and its many variations are ubiquitous tools for image processing and analysis. In many imaging scenarios, the images of interest are corrupted by noise. This has a strong negative impact on the accuracy of the DT, which is highly sensitive to spurious noise points. In this study, we consider images represented as discrete random sets and observe statistics of DT computed on such representations. We, thus, define a stochastic distance transform (SDT), which has an adjustable robustness to noise. Both a stochastic Monte Carlo method and a deterministic method for computing the SDT are proposed and compared. Through a series of empirical tests, we demonstrate that the SDT is effective not only in improving the accuracy of the computed distances in the presence of noise, but also in improving the performance of template matching and watershed segmentation of partially overlapping objects, which are examples of typical applications where DTs are utilized.


Distance transform Stochastic Robustness to noise Random sets Monte Carlo Template matching Watershed segmentation 



This work is supported by VINNOVA, MedTech4Health grants 2016-02329 and 2017-02447 and the Ministry of Education, Science, and Techn. Development of the Republic of Serbia (proj. ON174008 and III44006).


  1. 1.
    Angulo, J., Jeulin, D.: Stochastic watershed segmentation. In: Proceedings of the 8th International Symposium on Mathematical Morphology, pp. 265–276 (2007)Google Scholar
  2. 2.
    Baddeley, A., Molchanov, I.: Averaging of random sets based on their distance functions. J. Math. Imaging Vis. 8(1), 79–92 (1998)MathSciNetCrossRefGoogle Scholar
  3. 3.
    Bentley, J.L.: Multidimensional binary search trees used for associative searching. Commun. ACM 18(9), 509–517 (1975)CrossRefGoogle Scholar
  4. 4.
    Beucher, S.: Use of watersheds in contour detection. In: Proceedings of the International Workshop on Image Processing, CCETT (1979)Google Scholar
  5. 5.
    Borgefors, G.: Distance transformations in digital images. Comput. Vis. Graph. Image Process. 34(3), 344–371 (1986)CrossRefGoogle Scholar
  6. 6.
    Cuel, L., Lachaud, J.O., Mérigot, Q., Thibert, B.: Robust geometry estimation using the generalized voronoi covariance measure. SIAM J. Imaging Sci. 8(2), 1293–1314 (2015)MathSciNetCrossRefGoogle Scholar
  7. 7.
    Cuisenaire, O., Macq, B.: Fast k-NN classification with an optimal k-distance transformation algorithm. In: 2000 10th European Signal Processing Conference, pp. 1–4. IEEE (2000)Google Scholar
  8. 8.
    Eiter, T., Mannila, H.: Distance measures for point sets and their computation. Acta Informatica 34(2), 109–133 (1997)MathSciNetCrossRefGoogle Scholar
  9. 9.
    Goutsias, J.: Morphological analysis of discrete random shapes. J. Math. Imaging Vis. 2(2–3), 193–215 (1992)MathSciNetCrossRefGoogle Scholar
  10. 10.
    Gustavson, S., Strand, R.: Anti-aliased Euclidean distance transform. Pattern Recogn. Lett. 32(2), 252–257 (2011)CrossRefGoogle Scholar
  11. 11.
    Levi, G., Montanari, U.: A grey-weighted skeleton. Inf. Control 17(1), 62–91 (1970)CrossRefGoogle Scholar
  12. 12.
    Lewis, T., Owens, R., Baddeley, A.: Averaging feature maps. Pattern Recogn. 32(9), 1615–1630 (1999)CrossRefGoogle Scholar
  13. 13.
    Lindblad, J., Curic, V., Sladoje, N.: On set distances and their application to image registration. In: Proceedings of 6th International Symposium on Image and Signal Processing and Analysis, ISPA 2009, pp. 449–454. IEEE (2009)Google Scholar
  14. 14.
    Lindblad, J., Sladoje, N.: Exact linear time Euclidean distance transforms of grid line sampled shapes. In: Benediktsson, J.A., Chanussot, J., Najman, L., Talbot, H. (eds.) ISMM 2015. LNCS, vol. 9082, pp. 645–656. Springer, Cham (2015). Scholar
  15. 15.
    Matheron, G.: Random Sets and Integral Geometry. Wiley, New York (1975)zbMATHGoogle Scholar
  16. 16.
    Maurer, C.R., Qi, R., Raghavan, V.: A linear time algorithm for computing exact Euclidean distance transforms of binary images in arbitrary dimensions. IEEE Trans. Pattern Anal. Mach. Intell. 25(2), 265–270 (2003)CrossRefGoogle Scholar
  17. 17.
    Moreno, R., Koppal, S., De Muinck, E.: Robust estimation of distance between sets of points. Pattern Recogn. Lett. 34(16), 2192–2198 (2013)CrossRefGoogle Scholar
  18. 18.
    Rosenfeld, A., Pfaltz, J.L.: Sequential operations in digital picture processing. J. ACM (JACM) 13(4), 471–494 (1966)CrossRefGoogle Scholar
  19. 19.
    Saha, P.K., Borgefors, G., di Baja, G.S.: A survey on skeletonization algorithms and their applications. Pattern Recogn. Lett. 76, 3–12 (2016)CrossRefGoogle Scholar
  20. 20.
    Saha, P.K., Wehrli, F.W., Gomberg, B.R.: Fuzzy distance transform: theory, algorithms, and applications. Comput. Visi. Image Underst. 86(3), 171–190 (2002)CrossRefGoogle Scholar

Copyright information

© Springer Nature Switzerland AG 2019

Authors and Affiliations

  • Johan Öfverstedt
    • 1
    Email author
  • Joakim Lindblad
    • 1
    • 2
  • Nataša Sladoje
    • 1
    • 2
  1. 1.Centre for Image AnalysisUppsala UniversityUppsalaSweden
  2. 2.Mathematical Institute of the Serbian Academy of Sciences and ArtsBelgradeSerbia

Personalised recommendations