Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unable to launch dashboard #1676

Open
Bharat9280 opened this issue Aug 30, 2022 · 1 comment
Open

unable to launch dashboard #1676

Bharat9280 opened this issue Aug 30, 2022 · 1 comment

Comments

@Bharat9280
Copy link

Describe the bug
AttributeError Traceback (most recent call last)
Input In [15], in <cell line: 1>()
----> 1 ResponsibleAIDashboard(rai_insights, cohort_list=cohort_list)

File ~/.conda/envs/response/lib/python3.8/site-packages/raiwidgets/responsibleai_dashboard.py:34, in ResponsibleAIDashboard.init(self, analysis, public_ip, port, locale, cohort_list, **kwargs)
31 def init(self, analysis: RAIInsights,
32 public_ip=None, port=None, locale=None,
33 cohort_list=None, **kwargs):
---> 34 self.input = ResponsibleAIDashboardInput(
35 analysis, cohort_list=cohort_list)
37 super(ResponsibleAIDashboard, self).init(
38 dashboard_type="ResponsibleAI",
39 model_data=self.input.dashboard_input,
(...)
43 no_inline_dashboard=True,
44 **kwargs)
46 def predict():

File ~/.conda/envs/response/lib/python3.8/site-packages/raiwidgets/responsibleai_dashboard_input.py:41, in ResponsibleAIDashboardInput.init(self, analysis, cohort_list)
39 model = analysis.model
40 self._is_classifier = is_classifier(model)
---> 41 self.dashboard_input = analysis.get_data()
43 self._validate_cohort_list(cohort_list)
44 if cohort_list is not None:
45 # Add cohort_list to dashboard_input

File ~/.conda/envs/response/lib/python3.8/site-packages/responsibleai/rai_insights/rai_insights.py:498, in RAIInsights.get_data(self)
496 data.modelExplanationData = self.explainer.get_data()
497 data.errorAnalysisData = self.error_analysis.get_data()
--> 498 data.causalAnalysisData = self.causal.get_data()
499 data.counterfactualData = self.counterfactual.get_data()
500 return data

File ~/.conda/envs/response/lib/python3.8/site-packages/responsibleai/managers/causal_manager.py:435, in CausalManager.get_data(self)
430 def get_data(self):
431 """Get causal data
432 :return: List of CausalData objects.
433 :rtype: List[CausalData]
434 """
--> 435 return [result._get_dashboard_object() for result in self._results]

File ~/.conda/envs/response/lib/python3.8/site-packages/responsibleai/managers/causal_manager.py:435, in (.0)
430 def get_data(self):
431 """Get causal data
432 :return: List of CausalData objects.
433 :rtype: List[CausalData]
434 """
--> 435 return [result._get_dashboard_object() for result in self._results]

File ~/.conda/envs/response/lib/python3.8/site-packages/responsibleai/_tools/causal/causal_result.py:83, in CausalResult._get_dashboard_object(self)
80 def _get_dashboard_object(self):
81 causal_data = self._create_causal_data_object()
---> 83 causal_data.global_effects = self.global_effects
84 .reset_index().to_dict(orient='records')
85 local_dicts = self.local_effects.groupby('sample').apply(
86 lambda x: x.reset_index().to_dict(
87 orient='records')).values
88 causal_data.local_effects = [list(v) for v in local_dicts]

AttributeError: 'NoneType' object has no attribute 'reset_index'

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Stack trace
If applicable, please add the sdk stack trace for the error.

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Python version: [e.g. 3.9.12]
  • raiwidgets and responsibleai package versions [e.g. 0.19.0]

To get the package versions please run in your command line:

pip show raiwidgets
pip show responsibleai

Additional context
Add any other context about the problem here.

@gaugup
Copy link
Contributor

gaugup commented Aug 30, 2022

@Bharat9280 could you share a sample notebook that resulted in this stack trace? Was the causal computation successful?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants