0

I am currently working on a regression task using the LIME package in Python. I am trying to use the LimeTabularExplainer to help interpret my model's predictions.

Here is how my data is structured:

  • X_train and X_test have dimensions of (752, 15) and (188, 15) respectively,
  • y_train and y_test both have single dimensions of (752,) and (188,) respectively.

I am initializing the LimeTabularExplainer as follows:

from lime import lime_tabular

explainer = lime_tabular.LimeTabularExplainer(
    X_train, 
    mode="regression", 
    feature_names=X_feature_names
)

However, when I run this code, I receive the following error:

InvalidIndexError: (slice(None, None, None), 0)

I am not sure why this error is occurring. Any help understanding why I'm receiving this error and how to fix it would be greatly appreciated.

DataJanitor
  • 1,276
  • 1
  • 8
  • 19

0 Answers0