# zhoubolei/CAM

Class Activation Mapping

Repository: https://github.com/zhoubolei/CAM
Canonical: https://ross.abutalabs.com/products/cam
Homepage: http://cnnlocalization.csail.mit.edu/
Language: MATLAB
License: MIT
License Family: permissive
Last push: 2022-09-13T14:02:02+00:00

## Health v2 (maintenance only)
Score: 32/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 35, longevity 100
- inputs: {"age_days": 3796, "days_push": 1450, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1883, forks 461 (observed 2026-08-28T04:05:48.797679+00:00)

## What it is
Reference implementation of Class Activation Mapping (CAM), a CVPR'16 technique that visualizes which image regions a CNN attends to when predicting a class. It includes MATLAB/Caffe demo code with pre-trained GoogLeNet, VGG16, and AlexNet models plus a PyTorch script for generating heatmaps from modern networks.

## Use cases
- visualize what regions of an image a CNN focuses on for its prediction
- generate class activation heatmaps from pretrained ResNet or DenseNet in PyTorch
- extract weakly-supervised object bounding boxes from image-level labels
- interpret and debug CNN classification decisions
- reproduce the CVPR'16 CAM paper experiments on ImageNet and Places

## When to choose
- you need the original CAM method for research reproduction or citation
- you want heatmap visualization without modifying network architecture using GAP-based models
- you need pre-trained CAM models for Caffe on ImageNet or Places

## When to avoid
- you need modern explainability methods like Grad-CAM with finer localization
- your project requires actively maintained tooling or recent framework support
- you work outside Python/PyTorch or MATLAB/Caffe ecosystems

## Facets
- artifact type: library
- maturity: maintenance
- function: machine-learning, computer-vision, image-processing, data-visualization
- domain: deep-learning, computer-vision, image-processing, machine-learning
- platform: python, cross-platform
- tags: class-activation-mapping, cnn-visualization, saliency-maps, weakly-supervised-localization, cvpr-2016, pytorch, caffe, matlab

## Member repositories
- zhoubolei/CAM (main) score 32

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:48.797679+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:13:44.084626+00:00, confidence not recorded.
  - readme: https://github.com/zhoubolei/CAM (fetched 2026-08-28T04:05:48.797679+00:00, sha e54316ef222c)
  - homepage: http://cnnlocalization.csail.mit.edu/ (fetched 2026-08-29T10:52:58.556048+00:00, sha 819f3154190c)
- Data as of 2026-08-30T08:39:29.467469+00:00.
