bob.med.tb.utils.grad_cams

Classes

BaseWrapper(model)

GradCAM(model[, candidate_layers])

"Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localization" https://arxiv.org/pdf/1610.02391.pdf Look at Figure 2 on page 4

class bob.med.tb.utils.grad_cams.BaseWrapper(model)[source]

Bases: object

forward(image)[source]
backward(ids)[source]

Class-specific backpropagation

generate()[source]
remove_hook()[source]

Remove all the forward/backward hook functions

class bob.med.tb.utils.grad_cams.GradCAM(model, candidate_layers=None)[source]

Bases: bob.med.tb.utils.grad_cams.BaseWrapper

“Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localization” https://arxiv.org/pdf/1610.02391.pdf Look at Figure 2 on page 4

generate(target_layer)[source]