Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Ricardo Licona
deap_pBCI_Riemannian
Commits
d8549c9c
Commit
d8549c9c
authored
6 years ago
by
Ricardo Licona
Browse files
Options
Download
Email Patches
Plain Diff
Plot results classifiers.
parent
dff590d6
master
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
riemannian_utils/plot_results_classifiers.py
+59
-17
riemannian_utils/plot_results_classifiers.py
with
59 additions
and
17 deletions
+59
-17
riemannian_utils/plot_results_classifiers.py
+
59
-
17
View file @
d8549c9c
...
@@ -220,23 +220,65 @@ def plot_bayes(path):
...
@@ -220,23 +220,65 @@ def plot_bayes(path):
plt
.
title
(
'Valence and Arousal Average Accuracy for 32 Test Subjects
\n
GB Classifier'
)
plt
.
title
(
'Valence and Arousal Average Accuracy for 32 Test Subjects
\n
GB Classifier'
)
plt
.
savefig
(
'figures_plot_results/GG-GB-OFICIAL-15-36HZ.eps'
,
format
=
'eps'
,
dpi
=
1000
)
plt
.
savefig
(
'figures_plot_results/GG-GB-OFICIAL-15-36HZ.eps'
,
format
=
'eps'
,
dpi
=
1000
)
path1
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/FGMDM-OFICIAL-15-36HZ'
def
plot_lr_2
(
path
):
plot_fgmdm
(
path1
)
file
=
pd
.
read_csv
(
path
)
print
(
"---------------------------------------------------------------------"
)
path2
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/MDM-OFICIAL-15-36HZ'
print
(
"
\n
LR NTS: Perfomance Valence: "
,
file
.
valence_Score_Acc_3
.
mean
(),
"% - STD: "
,
file
.
valence_Score_Acc_3
.
std
())
plot_mdm
(
path2
)
print
(
"
\n
LR NTS Perfomance Arousal: "
,
file
.
arousal_Score_Acc_3
.
mean
(),
"% - STD: "
,
file
.
arousal_Score_Acc_3
.
std
())
path3
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/LR-TS-OFICIAL-15-36HZ'
plot_lr
(
path3
)
path4
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/SVM-TS-OFICIAL-15-36HZ'
plot_svm
(
path4
)
path5
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/SLDA-TS-OFICIAL-15-36HZ'
plt
.
plot
(
file
.
subject
,
file
.
valence_Score_Acc_3
,
color
=
'blue'
,
linewidth
=
1.0
,
linestyle
=
"-"
,
marker
=
'o'
,
plot_slda
(
path5
)
label
=
'Valence'
)
plt
.
plot
(
file
.
subject
,
file
.
arousal_Score_Acc_3
,
color
=
'red'
,
linewidth
=
1.0
,
linestyle
=
"-."
,
marker
=
'o'
,
label
=
'Arousal'
)
plt
.
ylabel
(
'Accuracy (in %)'
)
plt
.
xlabel
(
'Subjects'
)
plt
.
legend
()
plt
.
grid
(
True
)
plt
.
xlim
(
0
,
35
)
plt
.
title
(
'Valence and Arousal Average Accuracy for 32 Test Subjects
\n
LR Classifier'
)
plt
.
savefig
(
'figures_plot_results/GG-LR-OFICIAL-15-36HZ.eps'
,
format
=
'eps'
,
dpi
=
1000
)
path6
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/KNN-TS-OFICIAL-15-36HZ'
def
plot_slda_2
(
path
):
plot_knn
(
path6
)
file
=
pd
.
read_csv
(
path
)
print
(
"---------------------------------------------------------------------"
)
print
(
"
\n
sLDA NTS Perfomance Valence: "
,
file
.
valence_Score_Acc_3
.
mean
(),
"% - STD: "
,
file
.
valence_Score_Acc_3
.
std
())
print
(
"
\n
sLDA NTS Perfomance Arousal: "
,
file
.
arousal_Score_Acc_3
.
mean
(),
"% - STD: "
,
file
.
arousal_Score_Acc_3
.
std
())
plt
.
figure
()
plt
.
plot
(
file
.
subject
,
file
.
valence_Score_Acc_3
,
color
=
'blue'
,
linewidth
=
1.0
,
linestyle
=
"-"
,
marker
=
'o'
,
label
=
'Valence'
)
plt
.
plot
(
file
.
subject
,
file
.
arousal_Score_Acc_3
,
color
=
'red'
,
linewidth
=
1.0
,
linestyle
=
"-."
,
marker
=
'o'
,
label
=
'Arousal'
)
plt
.
ylabel
(
'Accuracy (in %)'
)
plt
.
xlabel
(
'Subjects'
)
plt
.
legend
()
plt
.
grid
(
True
)
plt
.
xlim
(
0
,
35
)
plt
.
title
(
'Valence and Arousal Average Accuracy for 32 Test Subjects
\n
sLDA Classifier'
)
plt
.
savefig
(
'figures_plot_results/GG-sLDA-OFICIAL-15-36HZ.eps'
,
format
=
'eps'
,
dpi
=
1000
)
path7
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/BAYES-TS-OFICIAL-15-36HZ'
# path1 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/FGMDM-OFICIAL-15-36HZ'
plot_bayes
(
path7
)
# plot_fgmdm(path1)
#
# path2 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/MDM-OFICIAL-15-36HZ'
# plot_mdm(path2)
#
# path3 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/LR-TS-OFICIAL-15-36HZ'
# plot_lr(path3)
#
# path4 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/SVM-TS-OFICIAL-15-36HZ'
# plot_svm(path4)
#
# path5 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/SLDA-TS-OFICIAL-15-36HZ'
# plot_slda(path5)
#
# path6 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/KNN-TS-OFICIAL-15-36HZ'
# plot_knn(path6)
#
# path7 = '/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/BAYES-TS-OFICIAL-15-36HZ'
# plot_bayes(path7)
path8
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/LR-NO-TS-OFICIAL-15-36HZ'
plot_lr_2
(
path8
)
path9
=
'/Users/ricklicona/PycharmProjects/deap_pBCI_Riemannian/DEAP/RIEMANNIAN_MDM/csv_results_classifiers/SLDA-NO-TS-OFICIAL-15-36HZ'
plot_slda_2
(
path9
)
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Snippets