提交 bd92c22b 编写于 作者: W WenmuZhou

Reduce saved information to reduce memory usage

上级 f7a62d94
...@@ -168,22 +168,27 @@ class DetectionIoUEvaluator(object): ...@@ -168,22 +168,27 @@ class DetectionIoUEvaluator(object):
numGlobalCareGt += numGtCare numGlobalCareGt += numGtCare
numGlobalCareDet += numDetCare numGlobalCareDet += numDetCare
# perSampleMetrics = {
# 'precision': precision,
# 'recall': recall,
# 'hmean': hmean,
# 'pairs': pairs,
# 'iouMat': [] if len(detPols) > 100 else iouMat.tolist(),
# 'gtPolPoints': gtPolPoints,
# 'detPolPoints': detPolPoints,
# 'gtCare': numGtCare,
# 'detCare': numDetCare,
# 'gtDontCare': gtDontCarePolsNum,
# 'detDontCare': detDontCarePolsNum,
# 'detMatched': detMatched,
# 'evaluationLog': evaluationLog
# }
perSampleMetrics = { perSampleMetrics = {
'precision': precision,
'recall': recall,
'hmean': hmean,
'pairs': pairs,
'iouMat': [] if len(detPols) > 100 else iouMat.tolist(),
'gtPolPoints': gtPolPoints,
'detPolPoints': detPolPoints,
'gtCare': numGtCare, 'gtCare': numGtCare,
'detCare': numDetCare, 'detCare': numDetCare,
'gtDontCare': gtDontCarePolsNum,
'detDontCare': detDontCarePolsNum,
'detMatched': detMatched, 'detMatched': detMatched,
'evaluationLog': evaluationLog
} }
return perSampleMetrics return perSampleMetrics
def combine_results(self, results): def combine_results(self, results):
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册