HomeAI & Machine LearningGrad-CAM: Where a Medical-Scan AI Is Looking

Grad-CAM: Where a Medical-Scan AI Is Looking

Interactive Class Activation Mapping simulator: a hand-built convolutional network classifies a synthetic medical scan as Normal or Abnormal, and a real gradient-weighted class activation map (Grad-CAM/CAM) shows exactly which pixels drove that decision.

AI & Machine Learning3DAdvanced60 FPS📱 Mobile-adapted⇄ 2D version
medical-imaging-ai ↗ Open standalone

Deep classifiers reading X-rays, CT slices and dermoscopy images are only trustworthy if a clinician can see why a model called a scan abnormal. This simulator runs a real, hand-specified two-layer convolutional network — actual 3×3 convolutions, ReLU, max-pooling, global average pooling and a linear head — over a synthetic scan containing a movable, adjustable-contrast lesion, then computes a genuine Class Activation Map: the gradient-weighted sum of the final convolutional layer's feature maps that reduces, for a global-average-pooled linear head, to the exact formula used in real Grad-CAM interpretability tooling. Drag the lesion around, watch the 3D bar-chart feature maps at each layer light up, switch which class is being explained, and compare the coarse-but-class-aware final-layer heatmap against a sharp-but-class-blind raw filter response from layer one — then check the live Intersection-over-Union score against the lesion's true location to see how faithfully the model's attention actually tracks the pathology.

⚙ Under the hood

Watch a real two-layer convolutional network classify a synthetic medical scan as Normal or Abnormal, then compute a genuine Class Activation Map (Grad-CAM) showing exactly which pixels drove the decision.

Grad-CAMexplainable AImedical imagingCNNinterpretability

3D · Three.js / WebGL renderer · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)