PAMIL
Prototype-attention multiple instance learning that classifies a whole slide image from a bag of patch features.
Medical imaging · 59 operations Checked
Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.
At a glance
- Task
- Medical imaging
- Parameters
- 801.8K
- Operations
- 59
- Framework
- PyTorch
- Recurrent
- No
- Published
- MICCAI 2024
- Paper
- PAMIL: Prototype Attention-Based Multiple Instance Learning for Whole Slide Image Classification
- Cited by
- 17 (as of 28 October 2026)
- Authors
- Jiashuai Liu, Anyu Mao, Yi Niu and others
- Source
- GitHub: Jiashuai-Liu/PAMIL
- Checked
- Passed: the trace was replayed operation by operation and matched the model's own output for this input.
Files
The file opened in a new tab. Use your browser's Save command there to keep it.
The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.
Details
- Stable ID
- m19036
- Graph hash
- 5dc8a9b24170bec56b766c1851d188e561f11e1513c890849e29a13fb61b638f
- Skeleton hash
- f84b0b2b2e56c08be1b5d860bb32c3eab66be92b5704d89851e797837ebd0029
- Architecture hash
- 54bbcb60f6e505852e8047a30a116d4f9317aa00ce7c34b5841756468454ba11
- Diagram SHA-256
- fdaa14f7849e8bf3ebaa09f485ee348be2e8410be9c1fb101a99b0d9b0eb8f18
- TorchLens version
- 2.36.0
- Renderer
- graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
- Check
- Forward pass replayed in PyTorch
What it is
PAMIL (Prototype Attention-based Multiple Instance Learning) classifies whole slide images in digital pathology, treating each slide as a bag and its patches as instances. The method is designed to make the model's reasoning easier to interpret without giving up classification performance at the slide level.
The model works on patch embeddings and a set of global prototypes, initialized by running K-means clustering twice over the instance embeddings of all bags. Cross-attention between instances and prototypes gives a similarity matrix, and two branches use it. In the instance branch, a learnable weight matrix maps instance-to-prototype similarity to instance-to-category attention. In the prototype branch, the same similarity matrix aggregates the prototype embeddings into a second bag-level feature for a second classifier. The final prediction is the average of the two probabilities, and a regularization loss keeps the two branch predictions consistent.
Unlike ProtoMIL, the prototypes have no predefined categories, which lets PAMIL handle both multi-label and multi-class tasks. The paper evaluates it on four public datasets for multi-class or multi-label slide classification. In its ablation study, removing the regularization loss made the model worse than a single-branch prediction.
Key idea. PAMIL embeds prototypes into the attention mechanism of multiple instance learning to measure prototype-instance similarity, giving prototype-level and instance-level interpretation of a slide prediction.
- pamil
- prototype attention-based multiple instance learning
- multiple instance learning
- whole slide image classification
- prototype learning
- digital pathology
- wsi classification
- interpretable mil
AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.
Cite the paper
@inbook{Liu_2024, title={PAMIL: Prototype Attention-Based Multiple Instance Learning for Whole Slide Image Classification}, ISBN={9783031720833}, ISSN={1611-3349}, url={http://dx.doi.org/10.1007/978-3-031-72083-3_34}, DOI={10.1007/978-3-031-72083-3_34}, booktitle={Medical Image Computing and Computer Assisted Intervention – MICCAI 2024}, publisher={Springer Nature Switzerland}, author={Liu, Jiashuai and Mao, Anyu and Niu, Yi and Zhang, Xianli and Gong, Tieliang and Li, Chen and Gao, Zeyu}, year={2024}, pages={362–372} }