Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(662)

Unified Diff: webrtc/modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores_factory.py

Issue 2813883002: APM QA refactoring: render stream support, echo path simulation, new export engine (Closed)
Patch Set: merge Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores_factory.py
diff --git a/webrtc/modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores_factory.py b/webrtc/modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores_factory.py
index 4ce6458cf158b2c2e508b3ff390120a0ce1aa1bc..c19e1f9ceffab947b28bd30b3cefdfa59b636adc 100644
--- a/webrtc/modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores_factory.py
+++ b/webrtc/modules/audio_processing/test/py_quality_assessment/quality_assessment/eval_scores_factory.py
@@ -21,7 +21,8 @@ class EvaluationScoreWorkerFactory(object):
workers.
"""
- def __init__(self, polqa_tool_bin_path):
+ def __init__(self, score_filename_prefix, polqa_tool_bin_path):
+ self._score_filename_prefix = score_filename_prefix
self._polqa_tool_bin_path = polqa_tool_bin_path
def GetInstance(self, evaluation_score_class):
@@ -29,11 +30,14 @@ class EvaluationScoreWorkerFactory(object):
Args:
evaluation_score_class: EvaluationScore class object (not an instance).
+
+ Returns:
+ An EvaluationScore instance.
"""
logging.debug(
'factory producing a %s evaluation score', evaluation_score_class)
if evaluation_score_class == eval_scores.PolqaScore:
- return eval_scores.PolqaScore(self._polqa_tool_bin_path)
+ return eval_scores.PolqaScore(
+ self._score_filename_prefix, self._polqa_tool_bin_path)
else:
- # By default, no arguments in the constructor.
- return evaluation_score_class()
+ return evaluation_score_class(self._score_filename_prefix)

Powered by Google App Engine
This is Rietveld 408576698