Skip to content

Commit f7be02d

Browse files
committed
Readme
1 parent f8a1e7f commit f7be02d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ with GradCAM(model=model, target_layers=target_layers) as cam:
126126
[cam.py](https://github.com/jacobgil/pytorch-grad-cam/blob/master/cam.py) has a more detailed usage example.
127127

128128
----------
129-
# Choosing the Target Layer
129+
# Choosing the layer(s) to extract activations from
130130
You need to choose the target layer to compute the CAM for.
131131
Some common choices are:
132132
- FasterRCNN: model.backbone
@@ -136,8 +136,10 @@ Some common choices are:
136136
- ViT: model.blocks[-1].norm1
137137
- SwinT: model.layers[-1].blocks[-1].norm1
138138

139+
139140
If you pass a list with several layers, the CAM will be averaged accross them.
140141
This can be useful if you're not sure what layer will perform best.
142+
141143
----------
142144

143145
# Adapting for new architectures and tasks

0 commit comments

Comments
 (0)