Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion torchTextClassifiers/torchTextClassifiers.py
Original file line number Diff line number Diff line change
Expand Up @@ -708,7 +708,7 @@ def predict(
explain_with_captum (bool): launch gradient integration with Captum for explanation (default: False)

Returns: A dictionary containing the following fields:
- predictions (torch.Tensor, shape (len(text), top_k)): A tensor containing the top_k most likely codes to the query.
- prediction (torch.Tensor | np.ndarray, shape (len(text), top_k)): A tensor containing the top_k most likely codes to the query.
- confidence (torch.Tensor, shape (len(text), top_k)): A tensor array containing the corresponding confidence scores.
- if explain is True:
- attributions (torch.Tensor, shape (len(text), top_k, seq_len)): A tensor containing the attributions for each token in the text.
Expand Down