You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I said in the title above sometimes ...because the behavior is random.
1-I did two tests, passing my Xtest data which have 5 variables and all works good.
but ones I pass into Smartexplainer a data frame with same format as Xtest but has more than 5 variables, the error bellow appear.
my table type is float32 based from input text originally. the error: AttributeError: 'DataFrame' object has no attribute 'dtype'.....which is not true
2-I tried to upgrade the shapash version but I still also have this warning
Code 👍
xpl = SmartExplainer(
model=model
)
xpl.compile(x=Xtest, y_pred=y_pred)
app = xpl.run_app()
\smart_app.py:126: FutureWarning:
DataFrame.applymap has been deprecated. Use DataFrame.map instead.
T
raceback (most recent call last):
Cell In[8], line 369
app = xpl.run_app()
File ~\anaconda3\Lib\site-packages\shapash\explainer\smart_explainer.py:1079 in run_app
self.smartapp = SmartApp(self, settings)
File ~\anaconda3\Lib\site-packages\shapash\webapp\smart_app.py:137 in init
self.init_data()
File ~\anaconda3\Lib\site-packages\shapash\webapp\smart_app.py:207 in init_data
typ = self.dataframe[col].dtype
File ~\anaconda3\Lib\site-packages\pandas\core\generic.py:6204 in getattr
return object.getattribute(self, name)
AttributeError: 'DataFrame' object has no attribute 'dtype'
Python version :Python 3.11.5 64-bit | Qt 5.15.2 | PyQt5 5.15.7 | Spyder IDE 5.4.3
Shapash version : 2.4.1
Operating System :Windows 10
The text was updated successfully, but these errors were encountered:
brahim7
changed the title
SmartExplainer: can not handle input data that have more than 5 variables
SmartExplainer: sometimes can not handle input data that have more than 5 variables
Jan 22, 2024
I said in the title above sometimes ...because the behavior is random.
1-I did two tests, passing my Xtest data which have 5 variables and all works good.
but ones I pass into Smartexplainer a data frame with same format as Xtest but has more than 5 variables, the error bellow appear.
my table type is float32 based from input text originally. the error: AttributeError: 'DataFrame' object has no attribute 'dtype'.....which is not true
2-I tried to upgrade the shapash version but I still also have this warning
Code 👍
xpl = SmartExplainer(
model=model
)
xpl.compile(x=Xtest, y_pred=y_pred)
app = xpl.run_app()
\smart_app.py:126: FutureWarning:
DataFrame.applymap has been deprecated. Use DataFrame.map instead.
T
raceback (most recent call last):
Cell In[8], line 369
app = xpl.run_app()
File ~\anaconda3\Lib\site-packages\shapash\explainer\smart_explainer.py:1079 in run_app
self.smartapp = SmartApp(self, settings)
File ~\anaconda3\Lib\site-packages\shapash\webapp\smart_app.py:137 in init
self.init_data()
File ~\anaconda3\Lib\site-packages\shapash\webapp\smart_app.py:207 in init_data
typ = self.dataframe[col].dtype
File ~\anaconda3\Lib\site-packages\pandas\core\generic.py:6204 in getattr
return object.getattribute(self, name)
AttributeError: 'DataFrame' object has no attribute 'dtype'
Python version :Python 3.11.5 64-bit | Qt 5.15.2 | PyQt5 5.15.7 | Spyder IDE 5.4.3
Shapash version : 2.4.1
Operating System :Windows 10
The text was updated successfully, but these errors were encountered: