Towards Classifying Histopathological Microscope Images as Time Series Data

Sungrae Hong, Hyeongmin Park, Young Sin Ko, Sol Lee, Bryan Wong, Mun Yong Yi

TL;DR

This paper introduces a novel framework that treats manually captured microscope image sequences as time-series data rather than unordered collections. By leveraging Dynamic Time Warping (DTW) and attention-based pooling, the authors successfully address the "messiness" of manual microscopy—such as redundant frames and inconsistent sequence lengths—outperforming standard Multiple Instance Learning (MIL) and traditional sequence models in cancer diagnosis tasks.

What Problem Does This Paper Address?

In modern digital pathology, most deep learning research focuses on scanners that produce high-resolution Whole-Slide Images (WSIs). However, scanners are expensive (tens of thousands of dollars), making them less accessible in many clinical settings and developing nations.

In contrast, microscopes are affordable and provide rapid results, but they present four major hurdles for AI:

  1. Arbitrary Locations: Images are captured as a pathologist moves the slide; there are no fixed coordinates.
  2. Inconsistent Length: The number of images captured per case varies wildly.
  3. Duplications: Manual operation often results in many redundant, overlapping images.
  4. Weak Labels: Pathologists usually provide one diagnosis for the entire set of images, not for each individual frame.

Existing models usually treat these images as a "bag" (Multiple Instance Learning) or a simple sequence, often ignoring the temporal logic of how a pathologist actually examines a slide.

Methods

The authors propose a multi-stage pipeline to transform raw microscope sequences into reliable classifications:

  • Data Cleaning: They use Time Series Differencing to remove redundant, nearly identical frames based on L2 distance.
  • Wavelet Transformation: The sequence is split into "stable" components (slow movements/zooming) and "rapid" components (quick shifts to new regions).
  • Dual-Path Attention: The model uses Self-Attention to find key features within the sequence and Cross-Attention to integrate the stable and rapid components.
  • The "Implicit Target" & Soft-DTW: This is the most novel part. Since they don't have labels for every frame, they use a Beta distribution curve as an "implicit target." This mimics the empirical observation that pathologists take a few frames to find and zoom into a symptomatic region. They then use Soft-Dynamic Time Warping (Soft-DTW) to calculate the loss between the predicted sequence and this ideal temporal curve.
  • Attention Pooling (AP): In parallel, the model aggregates the entire sequence into a single vector to make a global prediction.

Datasets

The model was evaluated on two primary datasets:

  1. BreakHis: A well-known benchmark of breast histopathology images at four magnifications (40× to 400×).
  2. SMF (Seegene Medical Foundation): A private dataset of colon polyp images with mixed magnifications, representing a more challenging, "real-world" scenario.

Key Insights and Ideas

  • Temporal Order Matters: Unlike standard MIL, which treats images as an unordered bag, this paper argues that the sequence of acquisition contains latent information about what the pathologist deemed important.
  • The Beta Distribution Heuristic: By assuming that the "diagnostic" frames likely appear later in a sequence (after the pathologist finds the area of interest), the authors provide the model with a "soft" temporal guide that compensates for the lack of per-frame labels.
  • Complementary Inference: The authors found that combining different inference strategies—predicting via the pooled embedding, the DTW distance, and K-Nearest Neighbors—through majority voting yielded the most stable and accurate results.

Key Results

The proposed method consistently outperformed baselines like LSTM, GRU, and state-of-the-art MIL models (ABMIL, TransMIL).

  • SMF Dataset: Achieved an Accuracy of 0.991 and an F1-score of 0.990, significantly higher than TransMIL (0.978 Accuracy).
  • BreakHis Dataset: Across all magnifications, the model showed superior performance. For example, at 400× magnification, it achieved 0.957 Accuracy using KNN inference, compared to 0.893 for standard sequence models like LSTM.
  • Ablation Studies: Removing the Wavelet transformation or the "Implicit Target" led to noticeable performance drops, confirming that both the frequency-based splitting and the temporal loss are vital.

Limitations and Future Work

While the paper demonstrates strong results, a few areas remain open for exploration:

  • Heuristic Dependency: The use of a Beta(3, 20) distribution as an implicit target is a heuristic based on specific observations. It may need tuning for different medical specialties or different pathologist "searching" styles.
  • Computational Overhead: Using DTW and complex attention mechanisms on long sequences is more computationally expensive than simple MIL.
  • Generalization: The study focuses on breast and colon tissue. Future work could investigate if these temporal patterns hold true for other types of cancer or different imaging modalities (like cytology).

By treating the pathologist's workflow as a time series, this research bridges the gap between low-cost manual microscopy and high-performance deep learning.

Summary updated

BibTeX
@inproceedings{hong2025towards,
  author = {Sungrae Hong and Hyeongmin Park and Young Sin Ko and Sol Lee and Bryan Wong and Mun Yong Yi},
  title = {{Towards Classifying Histopathological Microscope Images as Time Series Data}},
  booktitle = {ISBI},
  year = {2025},
  url = {https://openreview.net/forum?id=eBGr2ym0YZ},
}

Loading related content...

Figure