dianna-ai / dianna

Deep Insight And Neural Network Analysis
https://dianna.readthedocs.io
Apache License 2.0
48 stars 13 forks source link

Add EU law example to dashboard #867

Closed laurasootes closed 1 month ago

laurasootes commented 1 month ago

This PR adds the example from the EU law text classification notebook to the dashboard. The example is only available for LIME (as in the notebook). In the dashboard, the user can select one of the 5 example sentences that are also in the notebook.

Following the notebook, I added the functions that are specific to this example to the models utils. Adding this example also required two additional imports for the dashboard installation Additionally, I added “number of samples” as an adjustable LIME parameter in the dashboard, as it is required by

Two comments on this example:

elboyran commented 1 month ago

@laurasootes, the dashboard tests are failing. I will review your PR (a very quick job, great!) when it's all green, and we can merge it then right away.

laurasootes commented 1 month ago

@elboyran the dashboard tests pass again :)

elboyran commented 1 month ago

Unfortunately, I cannot make it run on my machine. I installed missing packages and still cannot find the trained model, despite me putting it there explicitly :-( I hope @cwmeijer will be able to review it.

cwmeijer commented 1 month ago

Unfortunately, I cannot make it run on my machine. I installed missing packages and still cannot find the trained model, despite me putting it there explicitly :-( I hope @cwmeijer will be able to review it.

It worked for me. I ran:

pip install -e .[dashboard,dev,text]
dianna-dashboard