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

Unified Diff: webrtc/modules/audio_processing/test/py_quality_assessment/apm_quality_assessment.py

Issue 2811953002: APM QA unit tests, fake POLQA binary and minor fixes (Closed)
Patch Set: comments addressed Created 3 years, 8 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/apm_quality_assessment.py
diff --git a/webrtc/modules/audio_processing/test/py_quality_assessment/apm_quality_assessment.py b/webrtc/modules/audio_processing/test/py_quality_assessment/apm_quality_assessment.py
index 9cf1c7f039b257dc03936a964745d505b3dbbe16..b495a74f3c5bda26081b546b09721eeac0194f44 100755
--- a/webrtc/modules/audio_processing/test/py_quality_assessment/apm_quality_assessment.py
+++ b/webrtc/modules/audio_processing/test/py_quality_assessment/apm_quality_assessment.py
@@ -19,9 +19,12 @@ Usage: apm_quality_assessment.py -i audio1.wav [audio2.wav ...]
import argparse
import logging
+import os
import sys
+import quality_assessment.audioproc_wrapper as audioproc_wrapper
import quality_assessment.eval_scores as eval_scores
+import quality_assessment.evaluation as evaluation
import quality_assessment.test_data_generation as test_data_generation
import quality_assessment.simulation as simulation
@@ -33,6 +36,8 @@ _EVAL_SCORE_WORKER_NAMES = _EVAL_SCORE_WORKER_CLASSES.keys()
_DEFAULT_CONFIG_FILE = 'apm_configs/default.json'
+_POLQA_BIN_NAME = 'PolqaOem64'
+
def _InstanceArgumentsParser():
"""Arguments parser factory.
@@ -85,7 +90,9 @@ def main():
simulator = simulation.ApmModuleSimulator(
aechen_ir_database_path=args.air_db_path,
- polqa_tool_path=args.polqa_path)
+ polqa_tool_bin_path=os.path.join(args.polqa_path, _POLQA_BIN_NAME),
+ ap_wrapper=audioproc_wrapper.AudioProcWrapper(),
+ evaluator=evaluation.ApmModuleEvaluator())
simulator.Run(
config_filepaths=args.config_files,
input_filepaths=args.input_files,

Powered by Google App Engine
This is Rietveld 408576698