captum
captum copied to clipboard
Model interpretability and understanding for PyTorch
# my model ```python class Longformer_Net(nn.Module): def __init__(self, model_name, device, add_special_tokens=False, bidirectional=False, num_layers=1): super().__init__() self.device = device self.add_special_tokens = add_special_tokens self.model_name = model_name # model_name = 'pre-model/' + 'longformer-base-4096' self.config...
# Captum RISE API Design ## Background RISE (Randomized Input Sampling for Explanation) is a perturbation based approach to compute attribution. RISE uses a Monte-Carlo approximation algorithm to detect the...
Hi All, I have to compute gradient on BERT model on inferentia. For this I guess I also need access to the hidden layers. Im currently not able to proceed...
## Issue I am trying to use the Captum library to get attributions for my sequence-to-sequence T5 model. However the attributions are returned to the input token of the **decoder**...
## ❓ Questions and Help Hello, I have been attempting to adapt the TCAV tutorial for a fine-tuned DistilBERT model. My task involves sentiment classification for positive and negative reviews...
## 🐛 Bug When `torch.exp` is present in the model in any form, including softmax, logsoftmax, and logsumexp operations, the deltas seem to get pretty big for my model. I've...
## ❓ Questions and Help Hi, I am having troubles with LRP and my model ResNet101. As input i give metrod my image as a tensor and as target i...
## 🐛 Bug When running the example script `python -m captum.insights.example`, the interpreter raised an exception KeyError: 'WERKZEUG_SERVER_FD' ## To Reproduce I installed the following dependencies in my pyproject.toml in...
## ❓ Questions and Help When doing inference on a trained `BertForSequenceClassification` model (which has a [BertModel](https://huggingface.co/docs/transformers/v4.27.2/en/model_doc/bert#transformers.BertModel) as its base), I get slightly different results for 1. `IntegratedGradients `and inputting...