What if analysis within Visual analyses Lab

Options
lynnjrp
lynnjrp Registered Posts: 1

I'm running into "External code failed" error when I try to run a What If? analysis within the Visual Analyses.


Operating system used: Linux

Answers

  • AdrienL
    AdrienL Dataiker, Alpha Tester Posts: 196 Dataiker
    Options

    Hi,

    • What is the DSS version?
    • Can you paste the full content of the small text box below "Could not compute EXPLANATIONS"?
  • lji
    lji Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 5
    edited July 17
    Options

    version 12.4

    Could not compute EXPLANATIONS : <class 'Exception'> : Explainer isn't ready

    Traceback (most recent call last):  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 100, in start    self._handle_compute_explanation(interactive_scorer, params["computation_params"], params["records"])  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 55, in _handle_compute_explanation    prediction_df, explanations_df = interactive_scorer.explain(computation_params, records)  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 195, in explain    explanation_method=computation_params.get("explanationMethod"))  File "/opt/dataiku/python/dataiku/core/saved_model.py", line 1348, in predict    n_explanations_mc_steps))  File "/opt/dataiku/python/dataiku/core/saved_model.py", line 1320, in _predict_partition    explanation_method, n_explanations, n_explanations_mc_steps)  File "/opt/dataiku/python/dataiku/core/saved_model.py", line 1026, in predict    n_explanations, n_explanations_mc_steps)  File "/opt/dataiku/python/dataiku/core/saved_model.py", line 878, in _compute_explanations    shapley_background_size=mc_steps)  File "/opt/dataiku/python/dataiku/doctor/individual_explainer.py", line 149, in explain    raise Exception("Explainer isn't ready")Exception: Explainer isn't ready  File "/usr/lib64/python3.6/runpy.py", line 193, in _run_module_as_main    "__main__", mod_spec)  File "/usr/lib64/python3.6/runpy.py", line 85, in _run_code    exec(code, run_globals)  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 251, in <module>    serve(int(sys.argv[1]), sys.argv[2])  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 242, in serve    interactive_model.start()  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 108, in start    self._handle_command_exception(e)  File "/opt/dataiku/python/dataiku/doctor/interactive_model/server.py", line 82, in _handle_command_exception    traceback.print_stack()[2024-04-25 20:42:09,851] [25/MainThread] [ERROR] [__main__] Explainer isn't ready
  • lji
    lji Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 5
    Options

    I replied with the wrong account. lji is also the author's account. Thanks.

  • AdrienL
    AdrienL Dataiker, Alpha Tester Posts: 196 Dataiker
    Options

    I see this is a partitioned model. For at least one of the partitions, do you have less than 25 rows in your test set?

    You can see that in either the Summary or the Training information tab of each partition.

    If one of the partition has less than 25 rows, then it may not be able to load the explanations.

  • AdrienL
    AdrienL Dataiker, Alpha Tester Posts: 196 Dataiker
    Options

    Also, in that case, the prediction should work, and only the explanations would fail.

    what-if explanations error.png

    In that case, you can simply disable the explanations to make the error disappear.

  • lji
    lji Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 5
    Options

    Thank you! How can the explanation feature be disabled?

  • AdrienL
    AdrienL Dataiker, Alpha Tester Posts: 196 Dataiker
    Options

    You can click the toggle below the score / above the explanations part, highlighted in green herewhat-if explanations error toggle.png

Setup Info
    Tags
      Help me…