Skip to content

[WIP] Added a confusion matrix plot generator. #274

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

Merged
merged 1 commit into from
Jun 25, 2021

Conversation

vytjan
Copy link
Collaborator

@vytjan vytjan commented Jun 24, 2021

refering to #242
@Ann-KathrinKiessner @dcwil @HenrikBons

@vytjan vytjan force-pushed the confusion_matrix branch from 3074313 to 8b6956e Compare June 24, 2021 09:02
@vytjan vytjan changed the title Added a confusion matrix plot generator. [WIP] Added a confusion matrix plot generator. Jun 24, 2021
@HenrikBons HenrikBons linked an issue Jun 24, 2021 that may be closed by this pull request
@robintibor
Copy link
Contributor

because ours much more beautiful! ;) See discussion end of #242 so it was considered ! But I would try to add the class names in the example

@robintibor
Copy link
Contributor

We agreed that we can keep like this (with own function that shows a bit more information than scikitlearn) depending on how strong @agramfort objects to it :D

@agramfort
Copy link
Collaborator

agramfort commented Jun 24, 2021 via email

@vytjan vytjan force-pushed the confusion_matrix branch from 8b6956e to c21b338 Compare June 25, 2021 10:48
confusion_mat = confusion_matrix(y_true, y_pred)

# add class labels
label_dict = valid_set.datasets[0].windows.event_id.items()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
label_dict = valid_set.datasets[0].windows.event_id.items()
# label_dict is class_name : str -> i_class : int
label_dict = valid_set.datasets[0].windows.event_id.items()

@robintibor
Copy link
Contributor

And maybe just add same code also for trialwise example, why not?

@vytjan vytjan force-pushed the confusion_matrix branch from 7271ab3 to 6257b91 Compare June 25, 2021 12:33
@robintibor robintibor merged commit 65b8de3 into braindecode:master Jun 25, 2021
@robintibor
Copy link
Contributor

Great work!

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

Successfully merging this pull request may close these issues.

How to draw result graphs?
3 participants