Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bob
bob.bio.base
Commits
15961f9f
Commit
15961f9f
authored
Jun 28, 2018
by
Theophile GENTILHOMME
Browse files
[script][figure] Change labels
parent
ca793710
Changes
1
Hide whitespace changes
Inline
Side-by-side
bob/bio/base/script/figure.py
View file @
15961f9f
...
...
@@ -11,8 +11,8 @@ from tabulate import tabulate
class
Roc
(
measure_figure
.
Roc
):
def
__init__
(
self
,
ctx
,
scores
,
evaluation
,
func_load
):
super
(
Roc
,
self
).
__init__
(
ctx
,
scores
,
evaluation
,
func_load
)
self
.
_x_label
=
ctx
.
meta
.
get
(
'x_label'
)
or
'F
alse Match Rate
'
default_y_label
=
'1 - F
alse Non Match Rate
'
if
self
.
_semilogx
\
self
.
_x_label
=
ctx
.
meta
.
get
(
'x_label'
)
or
'F
MR
'
default_y_label
=
'1 - F
NMR
'
if
self
.
_semilogx
\
else
'False Non Match Rate'
self
.
_y_label
=
ctx
.
meta
.
get
(
'y_label'
)
or
default_y_label
...
...
@@ -20,8 +20,8 @@ class Roc(measure_figure.Roc):
class
Det
(
measure_figure
.
Det
):
def
__init__
(
self
,
ctx
,
scores
,
evaluation
,
func_load
):
super
(
Det
,
self
).
__init__
(
ctx
,
scores
,
evaluation
,
func_load
)
self
.
_x_label
=
ctx
.
meta
.
get
(
'x_label'
)
or
'F
alse Match Rate
(%)'
self
.
_y_label
=
ctx
.
meta
.
get
(
'y_label'
)
or
'F
alse Non Match Rate
(%)'
self
.
_x_label
=
ctx
.
meta
.
get
(
'x_label'
)
or
'F
MR
(%)'
self
.
_y_label
=
ctx
.
meta
.
get
(
'y_label'
)
or
'F
NMR
(%)'
class
Cmc
(
measure_figure
.
PlotBase
):
...
...
@@ -30,7 +30,7 @@ class Cmc(measure_figure.PlotBase):
def
__init__
(
self
,
ctx
,
scores
,
evaluation
,
func_load
):
super
(
Cmc
,
self
).
__init__
(
ctx
,
scores
,
evaluation
,
func_load
)
self
.
_semilogx
=
ctx
.
meta
.
get
(
'semilogx'
,
True
)
self
.
_titles
=
self
.
_titles
or
[
'CMC dev'
,
'CMC eval'
]
self
.
_titles
=
self
.
_titles
or
[
'CMC dev
.
'
,
'CMC eval
.
'
]
self
.
_x_label
=
self
.
_x_label
or
'Rank'
self
.
_y_label
=
self
.
_y_label
or
'Identification rate'
self
.
_max_R
=
0
...
...
@@ -76,7 +76,7 @@ class Dir(measure_figure.PlotBase):
self
.
_rank
=
ctx
.
meta
.
get
(
'rank'
,
1
)
self
.
_titles
=
self
.
_titles
or
[
'DIR curve'
]
*
2
self
.
_x_label
=
self
.
_x_label
or
'False Alarm Rate'
self
.
_y_label
=
self
.
_y_label
or
'D
etection and Identification Rate
'
self
.
_y_label
=
self
.
_y_label
or
'D
IR
'
def
compute
(
self
,
idx
,
input_scores
,
input_names
):
''' Plot DIR for dev and eval data using
...
...
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