captum
captum copied to clipboard
VisualizationDataRecord with a regression task?
I'm fine-tuning BERT (using the Transformers library) to perform a regression task and I can successfully extract the attributions. However, how am I supposed to visualize the importance of different words using VisualizationDataRecord?
Its arguments seem to require at least three "classes" in the context of classification and a pred_prob, none of which I have.
word_attributions,
pred_prob,
pred_class,
true_class,
attr_class,
attr_score,
raw_input,
convergence_score,
As an aside, if the VisualizationDataRecord is designed for classification, shouldn't it be called ClassificationVisualizationDataRecord?
Another question: Can the documentation for VisualizationDataRecord be improved? For instance, what is attr_score or attr_class?
The regression tutorial (https://captum.ai/tutorials/House_Prices_Regression_Interpret) doesn't seem to use the VisualizationDataRecord. Is there another regression tutorial which does?
VisualizationDataRecord is only for text, @RylanSchaeffer ! I hope that you were able to visualize it with custom visualization UI. Can we close this issue ?
I am trying to visualize text. I think you might have misunderstood my question