[D] How can I improve cross-patient generalization on a small hysteroscopy dataset with correlated frames?

[D] How can I improve cross-patient generalization on a small hysteroscopy dataset with correlated frames?

I am working with the HS-CMU hysteroscopy dataset, which contains:

  • 3,385 frames from 175 patients.
  • Eight lesion classes, labelled from 0 to 7.
  • A highly imbalanced number of patients and frames across classes.
  • Multiple correlated frames from each patient.
  • Some frames containing more than one lesion class.

Before attempting the complete multiclass problem, I reduced it to a binary subset to verify that the training and evaluation pipeline works correctly.

Current binary subset

  • Selected lesion classes: 2 and 3.
  • Total: 1,575 frames from 113 unique patients.
  • Class 2: 1,054 frames from 78 patients.
  • Class 3: 521 frames from 36 patients.
  • One patient has different frames belonging to both classes but remains entirely within one split.

Patient-disjoint split

  • Training: 1,095 frames from 79 patients.
  • Validation: 241 frames from 17 patients.
  • Testing: 239 frames from 17 patients.
  • No patient appears in more than one subset.
  • The frame-level class distribution is approximately 67%/33% in every subset.

Approaches I have tried

  • DenseNet121, ViT, and DINOv2 backbones.
  • Frozen pretrained backbone with only the classifier trained.
  • Different classifier-head sizes and dropout.
  • Class-weighted cross-entropy.
  • Mild and stronger image augmentations.
  • Early stopping and learning-rate scheduling.
  • Unfreezing the final one or two encoder blocks.

With the correct patient-level split, training performance improves, but validation performance generally plateaus or deteriorates, and performance on unseen test patients remains relatively low.

As a diagnostic, I also tried a random frame-level split and obtained substantially better results. However, this evaluation is invalid because correlated frames from the same patients appear across training, validation, and testing, causing patient leakage and inflated performance.

I would appreciate advice on how to improve generalization to unseen patients in this setting.

submitted by /u/Aggravating_Dot5315
[comments]

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *