aboutsummaryrefslogtreecommitdiff
path: root/verif/conformance/tosa_verif_conformance_generator.py
diff options
context:
space:
mode:
authorJeremy Johnson <jeremy.johnson@arm.com>2023-04-13 17:18:19 +0100
committerJeremy Johnson <jeremy.johnson@arm.com>2023-04-26 14:32:01 +0100
commit0c71686875618b2e11290273b7a05b88ef8a8aae (patch)
tree533051a0c5befee3640639fdbd3fe122da21dd40 /verif/conformance/tosa_verif_conformance_generator.py
parentb2099706b3db022e8c4d85c4ae863086630e0678 (diff)
downloadreference_model-0c71686875618b2e11290273b7a05b88ef8a8aae.tar.gz
8K levels: Tensor op tests kernel/stride at 8192 maximums
Operators updated: AVG_POOL2D, MAX_POOL2D, CONV2D, CONV3D, DEPTHWISE_CONV2D & TRANSPOSE_CONV2D tosa_verif_build_tests argument --level-8k-sizes used to allow kernel/stride maximum boundary testing Fixed bugs in height/width validator function meaning some esixting avg_pool2d float tests need regening. Signed-off-by: Jeremy Johnson <jeremy.johnson@arm.com> Change-Id: I7aeab82d3bd3c49d02d54708f2c9d995cd3cf2df
Diffstat (limited to 'verif/conformance/tosa_verif_conformance_generator.py')
-rw-r--r--verif/conformance/tosa_verif_conformance_generator.py44
1 files changed, 23 insertions, 21 deletions
diff --git a/verif/conformance/tosa_verif_conformance_generator.py b/verif/conformance/tosa_verif_conformance_generator.py
index 2d9dad3..ef6bfb9 100644
--- a/verif/conformance/tosa_verif_conformance_generator.py
+++ b/verif/conformance/tosa_verif_conformance_generator.py
@@ -755,7 +755,29 @@ def main():
gen_neg_dim_range,
)
- if args.convert_all_tests:
+ # Work out which selection criteria we are using
+ if "selector" in gen_dict:
+ selector_name = gen_dict["selector"]
+ if selector_name not in test_params[op]["selection"]:
+ logger.warn(
+ f"Could not find {selector_name} in selection dict for {op} - using default"
+ )
+ selector_name = "default"
+ else:
+ selector_name = "default"
+ if selector_name not in test_params[op]["selection"]:
+ logger.error(
+ f"Could not find {selector_name} in selection dict for {op}"
+ )
+ raise (GenConformanceError())
+
+ # Selection criteria
+ selection_config = test_params[op]["selection"][selector_name]
+
+ if args.convert_all_tests or (
+ "all" in selection_config
+ and selection_config["all"] == "true"
+ ):
logger.debug(f"Running and converting all {op} tests")
generate_results(args, profile, op, op_build_dir)
operator_test_list = None
@@ -763,26 +785,6 @@ def main():
logger.debug(
f"Running and converting selection of {op} tests"
)
- # Work out which selection criteria we are using
- if "selector" in gen_dict:
- selector_name = gen_dict["selector"]
- if selector_name not in test_params[op]["selection"]:
- logger.warn(
- f"Could not find {selector_name} in selection dict for {op} - using default"
- )
- selector_name = "default"
- else:
- selector_name = "default"
- if selector_name not in test_params[op]["selection"]:
- logger.error(
- f"Could not find {selector_name} in selection dict for {op}"
- )
- raise (GenConformanceError())
-
- # Selection criteria
- selection_config = test_params[op]["selection"][
- selector_name
- ]
if test_type in ["positive", "both"]:
tests_gen, tests_gen2 = tee(
get_op_tests_selection(