Skip to content
Snippets Groups Projects
Commit f795fcf4 authored by function2's avatar function2
Browse files

fix white character issue #144

parent 26cbc064
No related branches found
No related tags found
No related merge requests found
......@@ -69,7 +69,7 @@ def unify_value(value, subtask):
ret[i] = unify_value(v, subtask)
return ret
return {
value = {
'multiwoz': {
'未提及': '',
'none': '',
......@@ -81,6 +81,8 @@ def unify_value(value, subtask):
}
}[subtask].get(value, value)
return ' '.join(value.strip().split())
def eval_states(gt, pred, subtask):
def exception(description, **kargs):
......@@ -135,7 +137,6 @@ def eval_states(gt, pred, subtask):
return {
'status': 'ok',
'joint accuracy': joint_acc / joint_tot,
# 'slot accuracy': slot_acc / slot_tot,
'slot': {
'accuracy': slot_acc / slot_tot,
'precision': precision,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment