tsai
tsai copied to clipboard
TSAI Explainability
Could you please add an example of how to use explainability using InceptionTimePlus? I'm not able to figure our the error.
TypeError: conv1d() received an invalid combination of arguments - got (numpy.ndarray, Parameter, NoneType, tuple, tuple, tuple, int), but expected one of:
- (Tensor input, Tensor weight, Tensor bias, tuple of ints stride, tuple of ints padding, tuple of ints dilation, int groups) didn't match because some of the arguments have invalid types: (!numpy.ndarray!, !Parameter!, !NoneType!, !tuple!, !tuple!, !tuple!, int)
- (Tensor input, Tensor weight, Tensor bias, tuple of ints stride, str padding, tuple of ints dilation, int groups) didn't match because some of the arguments have invalid types: (!numpy.ndarray!, !Parameter!, !NoneType!, !tuple!, !tuple!, !tuple!, int)
guys could you help me please?
Can you give more context?
Is there an example Jupyter notebook that shows how to use these explainability functions - get_attribution_map() and get_acts_and_grads(), with InceptionTime model?
Also it would be great if there is a document that shows how to interpret the output from both the functions. Does that makes sense?
Two explainability functions are documented here.
With InceptionTimePlus, you can call get_acts_and_grads with the module 'backbone' and will get the activations of that layer for any input x that you pass.
Hi @Diptendra, Please, take a look at this notebook. You may find it helpful.