From e1586d0ba1ee4d8343f59c3434f0647f6880a9f0 Mon Sep 17 00:00:00 2001 From: Pei Yao-Chang Date: Sat, 17 Aug 2024 08:59:59 +0800 Subject: [PATCH] Support gst_v4l2_video_decoder_performance_fakesink scenario (New) (#1337) * Support gst_v4l2_video_decoder_performance_fakesink scenario --------- Co-authored-by: stanley31huang --- .../bin/gst_resources_generator.py | 45 ++- .../bin/gst_v4l2_video_decoder_performance.py | 264 ++++++++++++++++++ .../bin/performance_mode_controller.py | 145 ++++++++++ .../video-codec-test-confs/genio-1200.json | 35 ++- .../video-codec-test-confs/genio-350.json | 34 ++- .../video-codec-test-confs/genio-510.json | 34 ++- .../video-codec-test-confs/genio-700.json | 34 ++- .../units/video-codec/jobs.pxu | 21 ++ .../units/video-codec/test-plan.pxu | 1 + 9 files changed, 599 insertions(+), 14 deletions(-) create mode 100755 contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_v4l2_video_decoder_performance.py create mode 100755 contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/performance_mode_controller.py diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_resources_generator.py b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_resources_generator.py index 0c412ddae7..97d489585c 100755 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_resources_generator.py +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_resources_generator.py @@ -31,11 +31,7 @@ def register_arguments() -> argparse.Namespace: parser = argparse.ArgumentParser( formatter_class=argparse.RawDescriptionHelpFormatter, - description=( - "Script helps verify the MD5 checksum from specific Gstreamer" - " Decoder with different resolutions and color spaces is exactly" - " match golden reference" - ), + description=("This script generates the resource for all scenarios"), ) parser.add_argument( @@ -64,6 +60,8 @@ def register_arguments() -> argparse.Namespace: class GstResources: + # video_golden_samples is the name of folder in hardware_codec_testing_data + # repo. https://github.com/canonical/hardware_codec_testing_data VIDEO_GOLDEN_SAMPLES = "video_golden_samples" def __init__(self, args: argparse.Namespace) -> None: @@ -101,14 +99,19 @@ def _v4l2_video_decoder_md5_checksum_comparison_helper( gst_v4l2_video_decoder_md5_checksum_comparison scenario """ name = "{}x{}-{}-{}".format(width, height, decoder_plugin, color_space) - golden_sample_file = "{}/video_golden_samples/{}.{}".format( - self._args.video_codec_testing_data_path, name, source_format + name_with_format = "{}.{}".format(name, source_format) + golden_sample_file = os.path.join( + self._args.video_codec_testing_data_path, + self.VIDEO_GOLDEN_SAMPLES, + name_with_format, ) - golden_md5_checkum_file = "{}/{}/golden_md5_checksum/{}/{}.md5".format( + md5_name = "{}.md5".format(name) + golden_md5_checkum_file = os.path.join( self._args.video_codec_testing_data_path, self._current_scenario_name, + "golden_md5_checksum", self._conf_name, - name, + md5_name, ) returned_dict = { @@ -171,6 +174,30 @@ def gst_v4l2_audio_video_synchronization( } ) + def gst_v4l2_video_decoder_performance_fakesink( + self, scenario_data: List[Dict] + ) -> None: + for item in scenario_data: + self._resource_items.append( + { + "scenario": self._current_scenario_name, + "decoder_plugin": item["decoder_plugin"], + "minimum_fps": item["minimum_fps"], + "golden_sample_file": os.path.join( + self._args.video_codec_testing_data_path, + self.VIDEO_GOLDEN_SAMPLES, + item["golden_sample_file"], + ), + # performance_target is "" means won't enable performance + # mode. + "performance_target": ( + self._args.video_codec_conf_file + if item["enable_performance_mode"] + else "" + ), + } + ) + def main(self): for scenario in self._scenarios: self._current_scenario_name = scenario diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_v4l2_video_decoder_performance.py b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_v4l2_video_decoder_performance.py new file mode 100755 index 0000000000..d963f98e53 --- /dev/null +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/gst_v4l2_video_decoder_performance.py @@ -0,0 +1,264 @@ +#!/usr/bin/env python3 +# This file is part of Checkbox. +# +# Copyright 2024 Canonical Ltd. +# Written by: +# Patrick Chang +# +# Checkbox is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License version 3, +# as published by the Free Software Foundation. +# +# Checkbox is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with Checkbox. If not, see . + +import argparse +import logging +import os +import re +import shlex +import subprocess + +from performance_mode_controller import get_performance_ctx_function + +logging.basicConfig(level=logging.INFO) + + +def register_arguments(): + parser = argparse.ArgumentParser( + formatter_class=argparse.RawDescriptionHelpFormatter, + description=( + "Script helps verify the performance of specific decoder won't" + " violate some Pass Criteria." + ), + ) + + parser.add_argument( + "-gp", + "--golden_sample_path", + required=True, + type=str, + help="Path of Golden Sample file", + ) + + parser.add_argument( + "-dp", + "--decoder_plugin", + required=True, + type=str, + help="Decoder plugin be used in gstreamer pipeline e.g. v4l2h264dec", + ) + + parser.add_argument( + "-s", + "--sink", + default="fakesink", + type=str, + help=("Specific sink that helps on judgement (default: fakesink)"), + ) + + parser.add_argument( + "-mf", + "--minimum_fps", + required=True, + type=str, + help=( + "The minimum value of FPS that " + "all average FPS value should not violate" + ), + ) + + parser.add_argument( + "-pmt", + "--performance_mode_target", + default="", + type=str, + help=( + "Once this value be assigned, script will enable performance mode" + " by the given value. For instance, if 'genio-1200' be assigned, " + "script will find the performance controller and execute the logic" + ' of genio-1200 board. (Default: "", will do nothing)' + ), + ) + + parser.add_argument( + "-fpss", + "--fpsdisplaysink_sync", + default="true", + type=str, + help=( + "The property option of fpsdisplaysink. (Default: true)" + "https://gstreamer.freedesktop.org/documentation/debugutilsbad/" + "fpsdisplaysink.html?gi-language=python#fpsdisplaysink:sync" + ), + ) + + args = parser.parse_args() + return args + + +def build_gst_command( + gst_bin: str, + golden_sample_path: str, + decoder: str, + sink: str, + fpsdisplaysink_sync: str, +) -> str: + """ + Builds a GStreamer command to process the golden sample. + + :param gst_bin: + The binary name of gstreamer. Default is "gst-launch-1.0" + You can assign the snap name to GST_LAUNCH_BIN env variable if you + want to using snap. + :param golden_sample: + The path to the golden sample file. + :param decoder: + The decoder to use for the video, e.g., "v4l2vp8dec", "v4l2vp9dec". + :param sink: + The desired sink option, e.g., "fakesink". + :param fpsdisplaysink_sync: + The property option of fpsdisplaysink." + Ref: https://gstreamer.freedesktop.org/documentation/debugutilsbad/ + fpsdisplaysink.html?gi-language=python#fpsdisplaysink:sync + + :returns: + The GStreamer command to execute. + """ + cmd = ( + "{} -v filesrc location={} ! parsebin ! queue ! {} ! queue ! " + "v4l2convert output-io-mode=dmabuf-import capture-io-mode=dmabuf ! " + 'queue ! fpsdisplaysink video-sink="{}"' + " text-overlay=false sync={}" + ).format(gst_bin, golden_sample_path, decoder, sink, fpsdisplaysink_sync) + + return cmd + + +def execute_command(cmd: str) -> str: + """ + Executes the GStreamer command and extracts the specific data from the + output. The specific data is the value of last-message which is exposed by + fpsdisplaysink. + + :param cmd: + The GStreamer command to execute. + + :returns: + The extracted last_message. + """ + try: + logging.info("Starting command: '{}'".format(cmd)) + ret = subprocess.run( + shlex.split(cmd), + check=True, + stdout=subprocess.PIPE, + stderr=subprocess.PIPE, + encoding="utf-8", + timeout=30, + ) + logging.info(ret.stdout) + return ret.stdout + except Exception as e: + raise SystemExit(e) + + +def is_valid_result(input_text: str, min_fps: float) -> bool: + """ + Extracts the last-message value from the given input string. + Example + last-message = rendered: 98, dropped: 0, current: 95.53, + average: 98.43 + Pass criteria + 1. The value of dropped frame must be 0 + 2. The value of average fps must greater than or equal to min_fps + + :param input_text: + The input string containing the data of last-message. + + :param min_fps: + A value that all average FPS must not fall below + + :returns: + True if the result meets the pass criteria; false otherwise . + """ + # Find all matches in the input text + pattern = re.compile(r"dropped: (\d+), current: [\d.]+, average: ([\d.]+)") + matches = pattern.findall(input_text) + if not matches: + logging.error("Unable to find any matching data.") + return False + for dropped, average in matches: + # Leave once a value doesn't match the pass criteria + if int(dropped) != 0 or float(average) < float(min_fps): + logging.error("Found values that violate the pass criteria.") + return False + return True + + +def main() -> None: + """ + This function performs the following steps: + + 1. Checks if the golden sample file exist. + 2. Builds a GStreamer command to process the golden sample using the + specified decoder. + 3. Executes the command and get the outcome back + 4. Judge the outcome to see if it meets the Pass Criteria + + :param args: + An object containing the following attributes: + - `golden_sample_path` (str): The path to the golden sample file. + - `decoder_plugin` (str): The video decoder to use, e.g., + "v4l2vp8dec", "v4l2vp9dec". + - `minimum_average_fps` (str): The minimum value of FPS + that all average FPS value should not violate + + :raises SystemExit: + If the golden sample file does not exist, or if the outcome violates + the pass criteria. + """ + args = register_arguments() + logging.info( + ( + "Pass Criteria \n" + " 1. All dropped frames must be 0\n" + " 2. All average fps values must greater than or equal to %s" + ), + args.minimum_fps, + ) + # Check the golden sample exixt + if not os.path.exists(args.golden_sample_path): + raise SystemExit( + "Golden Sample '{}' doesn't exist".format(args.golden_sample_path) + ) + gst_launch_bin = os.getenv("GST_LAUNCH_BIN", "gst-launch-1.0") + cmd = build_gst_command( + gst_bin=gst_launch_bin, + golden_sample_path=args.golden_sample_path, + decoder=args.decoder_plugin, + sink=args.sink, + fpsdisplaysink_sync=args.fpsdisplaysink_sync, + ) + + output = "" + + if args.performance_mode_target: + performance_mode_ctx = get_performance_ctx_function() + with performance_mode_ctx(platform=args.performance_mode_target): + output = execute_command(cmd).rstrip(os.linesep) + else: + output = execute_command(cmd).rstrip(os.linesep) + + if not is_valid_result(output, args.minimum_fps): + raise SystemExit(1) + logging.info("Pass") + + +if __name__ == "__main__": + main() diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/performance_mode_controller.py b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/performance_mode_controller.py new file mode 100755 index 0000000000..4c8b1e0f03 --- /dev/null +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/performance_mode_controller.py @@ -0,0 +1,145 @@ +#!/usr/bin/env python3 +# Since there are lots of devices from different projects need to run case +# with Performance mode, therefore, this script aims to be an unified entry +# and can be called by other scripts. As for the detail of each device, we +# implement it in each different specific script. + +# Copyright 2024 Canonical Ltd. +# Written by: +# Patrick Chang +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License version 3, +# as published by the Free Software Foundation. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +import importlib.util +import logging +import os +from importlib.machinery import SourceFileLoader +from typing import Callable, Optional + + +logging.basicConfig(level=logging.INFO) + + +def get_performance_ctx_function() -> Optional[Callable]: + """ + Get the specific context manager function of controlling performance mode. + The function helps you load a module which can not in the PYTHONPATH. + Therefore, developers can implement the python script of controlling + performance mode in each Checkbox Project and be used by ce-oem's script. + + Environment Variables: + ----------- + PERFORMANCE_PYTHON_MODULE_PATH + The full path of a python module that you are interested in even it's + not in PYTHONPATH + PERFORMANCE_FUNCTION_NAME + The name of ctx function to control the performance in a module. + + Returns: + -------- + Optional[Callable]: + The function object if found + + Raises: + ------- + SystemExit: + If the module or function cannot be loaded, the program exits. + """ + + # Get the full path of the specific python module which implements the + # real logic to control the enable and disable performance mode. + # In this way, we can leverage the performance python module which be + # implemented at each project checkbox instead of duplicating same script + # in ce-oem provider. + # It's the empty value by defaul, you have to define it as Checkbox's + # configuraion. + PERFORMANCE_PYTHON_MODULE_PATH = os.environ.get( + "PERFORMANCE_PYTHON_MODULE_PATH", "" + ) + if PERFORMANCE_PYTHON_MODULE_PATH == "": + raise FileNotFoundError( + ( + "Fail to get a performance python module" + "Please define the path in Checkbox configuration. " + "e.g. PERFORMANCE_PYTHON_MODULE_PATH=/path/of/the/module.py" + ) + ) + + # Get the name of context manager function which controls the performance + # mode. Default name is performance_mode. You can assign the specific name + # via environment variable + PERFORMANCE_FUNCTION_NAME = os.environ.get( + "PERFORMANCE_FUNCTION_NAME", "performance_mode" + ) + + return get_function_from_a_module( + module_name=os.path.basename(PERFORMANCE_PYTHON_MODULE_PATH), + module_path=PERFORMANCE_PYTHON_MODULE_PATH, + function_name=PERFORMANCE_FUNCTION_NAME, + ) + + +def get_function_from_a_module( + module_name: str, + module_path: str, + function_name: str, +) -> Optional[Callable]: + """ + Loads a module and retrieves a specified function. + + Parameters: + ----------- + module_name : str + The name of the module to load. + module_path : str + The full file path to the module. + function_name : str, optional + The name of the function to retrieve from the module + (default is "performance_mode"). + + Returns: + -------- + Optional[Callable]: + The function object if found + + Raises: + ------- + SystemExit: + If the module or function cannot be loaded, the program exits. + """ + try: + logging.info( + "Trying to load the '%s' module from '%s' to get '%s' function", + module_name, + module_path, + function_name, + ) + loader = SourceFileLoader(module_name, module_path) + spec = importlib.util.spec_from_loader(module_name, loader) + module = importlib.util.module_from_spec(spec) + loader.exec_module(module) + return getattr(module, function_name) + except FileNotFoundError: + logging.error( + "Module '%s' cannot be loaded since '%s' doesn't exist", + module_name, + module_path, + ) + raise + except AttributeError: + logging.error( + "Function '%s' not found in module '%s'", + function_name, + module_name, + ) + raise diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-1200.json b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-1200.json index 97d7a31b1a..278efcdb13 100644 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-1200.json +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-1200.json @@ -54,6 +54,37 @@ ] } ] - } + }, + "gst_v4l2_video_decoder_performance_fakesink": [ + { + "decoder_plugin": "v4l2h264dec", + "golden_sample_file": "H264_8Bit_High@L6.1_3840X2160_90Fps_160Mbps_AACLC-10sec.mp4", + "minimum_fps": 90, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2h265dec", + "golden_sample_file": "HEVC_8Bit_High@L5.2_3840X2160_90Fps_160Mbps_AACLC-10sec.mp4", + "minimum_fps": 90, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2mpeg4dec", + "golden_sample_file": "MPEG-4_1920x1080_60fps_60Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp8dec", + "golden_sample_file": "VP8_1920x1080_60fps_40Mbps.webm", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp9dec", + "golden_sample_file": "VP9_3840x2160_90fps_120Mbps.webm", + "minimum_fps": 90, + "enable_performance_mode": true + } + ] } - diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-350.json b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-350.json index d9979a9f63..665b27f96d 100644 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-350.json +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-350.json @@ -23,6 +23,38 @@ ] } ] - } + }, + "gst_v4l2_video_decoder_performance_fakesink": [ + { + "decoder_plugin": "v4l2h264dec", + "golden_sample_file": "H264_1920x1080_60fps_40Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2h265dec", + "golden_sample_file": "H265_1920x1080_60fps_40Mbps", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2mpeg4dec", + "golden_sample_file": "MPEG-4_1920x1080_60fps_40Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp8dec", + "golden_sample_file": "VP8_1920x1080_60fps_40Mbps.webm", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp9dec", + "golden_sample_file": "VP9_1920x1080_60fps_40Mbps.webm", + "minimum_fps": 60, + "enable_performance_mode": true + } + ] } diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-510.json b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-510.json index b64c271c59..76ef71bba7 100644 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-510.json +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-510.json @@ -28,6 +28,38 @@ ] } ] - } + }, + "gst_v4l2_video_decoder_performance_fakesink": [ + { + "decoder_plugin": "v4l2h264dec", + "golden_sample_file": "H264_3840x2160_75fps_160Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2h265dec", + "golden_sample_file": "H265_3840x2160_75fps_160Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2mpeg4dec", + "golden_sample_file": "MPEG-4_1920x1080_60fps_60Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp8dec", + "golden_sample_file": "VP8_1920x1080_60fps_40Mbps.webm", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp9dec", + "golden_sample_file": "VP9_3840x2160_75fps_120Mbps.webm", + "minimum_fps": 60, + "enable_performance_mode": true + } + ] } diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-700.json b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-700.json index b64c271c59..d1435f03c3 100644 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-700.json +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/data/video-codec-test-confs/genio-700.json @@ -28,6 +28,38 @@ ] } ] - } + }, + "gst_v4l2_video_decoder_performance_fakesink": [ + { + "decoder_plugin": "v4l2h264dec", + "golden_sample_file": "H264_3840x2160_75fps_160Mbps.mp4", + "minimum_fps": 75, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2h265dec", + "golden_sample_file": "H265_3840x2160_75fps_160Mbps.mp4", + "minimum_fps": 75, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2mpeg4dec", + "golden_sample_file": "MPEG-4_1920x1080_60fps_60Mbps.mp4", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp8dec", + "golden_sample_file": "VP8_1920x1080_60fps_40Mbps.webm", + "minimum_fps": 60, + "enable_performance_mode": true + }, + { + "decoder_plugin": "v4l2vp9dec", + "golden_sample_file": "VP9_3840x2160_75fps_120Mbps.webm", + "minimum_fps": 75, + "enable_performance_mode": true + } + ] } diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/jobs.pxu b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/jobs.pxu index 060509ebe2..0e26084713 100644 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/jobs.pxu +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/jobs.pxu @@ -54,3 +54,24 @@ _verification: 2. Is the timing of audio and video synchronized? command: gst_v4l2_audio_video_synchronization.py -dp {{decoder_plugin}} -gp {{golden_sample_file}} -vs {{video_sink}} -cp "{{capssetter_pipeline}}" + +unit: template +template-engine: jinja2 +template-resource: video_codec_resource +template-filter: video_codec_resource.scenario == "gst_v4l2_video_decoder_performance_fakesink" +template-unit: job +template-id: ce-oem-video-codec/gst_v4l2_video_decoder_performance_fakesink +_template-summary: To check if the performance of decoder doesn't violate Pass Criteria +id: ce-oem-video-codec/{{ scenario }}-{{ decoder_plugin }} +_summary: Performance test of decoder {{ decoder_plugin }} - fakesink +_description: Test if while the sink is fakesink, the decoder's performance, {{ decoder_plugin }}, doesn't violate the Pass Criteria. (1) There are no frame losses (2) Average FPS not fall below the specification's definition +plugin: shell +user: root +category_id: video-codec +estimated_duration: 1s +imports: from com.canonical.plainbox import manifest +requires: manifest.has_video_codec == 'True' +flags: also-after-suspend +environ: GST_LAUNCH_BIN, PERFORMANCE_PYTHON_MODULE_PATH, PERFORMANCE_FUNCTION_NAME +command: + gst_v4l2_video_decoder_performance.py -gp {{golden_sample_file}} -dp {{decoder_plugin}} -mf {{minimum_fps}} -pmt "{{performance_target}}" diff --git a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/test-plan.pxu b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/test-plan.pxu index 7b346f7824..3ae96c5604 100644 --- a/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/test-plan.pxu +++ b/contrib/checkbox-ce-oem/checkbox-provider-ce-oem/units/video-codec/test-plan.pxu @@ -24,3 +24,4 @@ bootstrap_include: video_codec_resource include: ce-oem-video-codec/gst_v4l2_video_decoder_md5_checksum_comparison + ce-oem-video-codec/gst_v4l2_video_decoder_performance_fakesink