diff options
author | Jeremy Johnson <jeremy.johnson@arm.com> | 2021-10-19 15:56:42 +0100 |
---|---|---|
committer | Eric Kunze <eric.kunze@arm.com> | 2021-10-21 18:32:52 +0000 |
commit | 58026d6839617f648ef8f7c6e106cf5acf2a4cc2 (patch) | |
tree | 400b1903da5840729acb16ce35655c9e9895ab78 /verif | |
parent | 5d00c69051bef9f27b60ba136c0efc49a45bf8e6 (diff) | |
download | reference_model-58026d6839617f648ef8f7c6e106cf5acf2a4cc2.tar.gz |
Fix pool2d generation and check to match specification
Change output size error_if check in ref model to match specification.
Remove size check from test generation as output shape is always
correctly calculated.
Change-Id: I5be64f31e6448b47e80fc0a4af11bb312f366a26
Signed-off-by: Jeremy Johnson <jeremy.johnson@arm.com>
Diffstat (limited to 'verif')
-rw-r--r-- | verif/tosa_test_gen.py | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/verif/tosa_test_gen.py b/verif/tosa_test_gen.py index 1f35b8b..04fce90 100644 --- a/verif/tosa_test_gen.py +++ b/verif/tosa_test_gen.py @@ -717,12 +717,6 @@ class TosaArgGen: for s in sorted(list(strides)): for p in sorted(list(paddings)): for k in sorted(list(kernels)): - # Calculate output height to test for error_if conditions - oh = (shape[1] + p[0] + p[1] + s[0] - k[0]) // s[0] - ow = (shape[2] + p[2] + p[3] + s[1] - k[1]) // s[1] - y = (oh * s[0]) - p[0] - p[1] - s[0] + k[0] - x = (ow * s[1]) - p[2] - p[3] - s[1] + k[1] - if error_name in [ErrorIf.StrideSmallerOne, ErrorIf.KernelSmallerOne, ErrorIf.PadSmallerZero, ErrorIf.PadLargerEqualKernel]: sNew, pNew, kNew = TosaErrorIfArgGen.eiPoolingErrorIf(testGen, error_name, s, p, k) if None not in [sNew, pNew, kNew] and n % sparsity == 0: @@ -741,7 +735,6 @@ class TosaArgGen: and p[0] < k[0] and p[1] < k[0] and p[2] < k[1] and p[3] < k[1] # the padded shape must exceed the kernel size and (shape[1] + p[0] + p[1]) > k[0] and (shape[2] + p[2] + p[3]) > k[1] - and y < shape[1] and x < shape[2] ): arg_list.append( ( |