Overcoming an annotation hurdle: Digitizing pen annotations from whole slide images

Peter Schüffler, Dig Yarlagadda, Chad Vanderbilt, Thomas Fuchs

Research output: Contribution to journalArticlepeer-review

2 Scopus citations


Background: The development of artificial intelligence (AI) in pathology frequently relies on digitally annotated whole slide images (WSI). The creation of these annotations-manually drawn by pathologists in digital slide viewers-is time consuming and expensive. At the same time, pathologists routinely annotate glass slides with a pen to outline cancerous regions, for example, for molecular assessment of the tissue. These pen annotations are currently considered artifacts and excluded from computational modeling. Methods: We propose a novel method to segment and fill hand-drawn pen annotations and convert them into a digital format to make them accessible for computational models. Our method is implemented in Python as an open source, publicly available software tool. Results: Our method is able to extract pen annotations from WSI and save them as annotation masks. On a data set of 319 WSI with pen markers, we validate our algorithm segmenting the annotations with an overall Dice metric of 0.942, Precision of 0.955, and Recall of 0.943. Processing all images takes 15 min in contrast to 5 h manual digital annotation time. Further, the approach is robust against text annotations. Conclusions: We envision that our method can take advantage of already pen-annotated slides in scenarios in which the annotations would be helpful for training computational models. We conclude that, considering the large archives of many pathology departments that are currently being digitized, our method will help to collect large numbers of training samples from those data.

Original languageEnglish
Article number9
JournalJournal of Pathology Informatics
Issue number1
StatePublished - 1 Jan 2021
Externally publishedYes


  • Computational pathology
  • digital pathology
  • pen annotations
  • training data generation


Dive into the research topics of 'Overcoming an annotation hurdle: Digitizing pen annotations from whole slide images'. Together they form a unique fingerprint.

Cite this