Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Michal Štefánik
ARQMath-eval
Commits
bcf29452
Unverified
Commit
bcf29452
authored
Apr 24, 2020
by
Vít Novotný
Browse files
Fix SIGSEGV
parent
d284ca37
Pipeline
#59123
failed with stage
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
scripts/common.py
View file @
bcf29452
...
...
@@ -103,6 +103,8 @@ def get_ndcg(parsed_run, task, subset):
"""
evaluator
=
EVALUATORS
[
subset
][
task
]
only_judged_parsed_run
=
_remove_nonjudged_topics_and_documents
(
parsed_run
,
task
,
subset
)
if
not
only_judged_parsed_run
:
return
0.0
evaluation
=
evaluator
.
evaluate
(
only_judged_parsed_run
)
ndcg
=
np
.
mean
([
measures
[
'ndcg'
]
for
topic
,
measures
in
evaluation
.
items
()])
return
ndcg
...
...
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