ShapleyExplanationNetworks
ShapleyExplanationNetworks copied to clipboard
Training and layers specifications
Dear all, Thank you very much for the well documented implementation. I have a couple of questions: 1- Is there a training script available to investigate the training loop of such networks? 2- Does the training require any special setting or is it optimizer for weights optimization based on loss function? 3- Is there any limitation on the used layers, I plan to build my own network with LSTM and embedding layers to process one hot encoded variables? Best regards,
Hi!
Thanks for your interests!
- The training of this model has nothing different compared to those of other models, you could just replace the model from any other usual training scripts.
- No, as I said above, this model can be treated as usual PyTorch models.
- As for the limitation of the layers, I believe you just need to make sure that for each output, there is a Shapley module wrapped around it. That being said, I'm not really sure how I would approach the problem of applying Shapley modules onto LSTMs.
Best, Rui
@RuiWang1998 Thank you very much for the fast reply. The reply clarifies a lot.
Dear all, Once again thank you for the code and your support. I had a couple of additional questions:
1- If I am only interested in the Shapley values between network inputs and final output, can I just use nn.Sequential with all my network layers defined inside it and wrap this sequential module inside a Shapley module
2- Can I use unexplained forward during the network training phase to reduce the computation error and use explained forward only in inference time?
3- When should I set the reference values to something else than a tensor of zeros? In the paper within the deepShapNet section, it is written that this depends on the application. Can expand on this note?
Just for context, I am using an autoencoder architecture for anomaly detection over a set of features. I am trying to use your implementation for finding the degree to which each feature contributes to anomaly detection.
I am really sorry for bothering you with all these questions and appreciate your help.
Best regards, Ahmed Radwan
Hi,
- You could do that but Shapley value computation is extremely hard if not decomposed into several feature subgroups.
- It does not seem to be possible, at least not off the top of my head.
- I suppose it depends on your use case? You could set them to the most sensible reference values for you problem.