Closed brrbaral closed 3 years ago
Thx for sharing the code. It seems that from a quick look it might be the case that your target column is being stripped out by the witwidget logic before sending the examples to the custom predict function, so you don't need the code in your custom predict fn to delete columns not used by model. Let me know if that helps.
Thanks, James for your response. It really worked.
Hi. I've got this error "IndexError('index 14 is out of bounds for axis 0 with size 14')". I tried using custom prediction function using keras model with reference to : https://colab.research.google.com/github/pair-code/what-if-tool/blob/master/WIT_COMPAS_with_SHAP.ipynb Here is my code: https://colab.research.google.com/drive/1rgmiCySj2UkwRuitrf0M6SIgfXINx1lp?usp=sharing Thanks.