diff options
m--------- | thirdparty/serialization_lib | 0 | ||||
-rw-r--r-- | verif/generator/tosa_test_gen.py | 51 |
2 files changed, 43 insertions, 8 deletions
diff --git a/thirdparty/serialization_lib b/thirdparty/serialization_lib -Subproject 4881c29247d4b411de446b13d9bd58ea93737aa +Subproject f5dfad14f0cdc9556785b610674350c2e5a3355 diff --git a/verif/generator/tosa_test_gen.py b/verif/generator/tosa_test_gen.py index 9dc3199..a83ead0 100644 --- a/verif/generator/tosa_test_gen.py +++ b/verif/generator/tosa_test_gen.py @@ -869,8 +869,11 @@ class TosaTestGen: ): return None + # TODO - Test local_bound, for now set local bound attribute to False + local_bound = False + attr = ts.TosaSerializerAttribute() - attr.ConvAttribute(padding, strides, dilations, qinfo[0], qinfo[1]) + attr.ConvAttribute(padding, strides, dilations, qinfo[0], qinfo[1], local_bound) self.ser.addOperator(op["op"], input_list, output_list, attr) @@ -948,8 +951,11 @@ class TosaTestGen: ): return None + # TODO - Test local_bound, for now set local bound attribute to False + local_bound = False + attr = ts.TosaSerializerAttribute() - attr.ConvAttribute(padding, strides, dilations, qinfo[0], qinfo[1]) + attr.ConvAttribute(padding, strides, dilations, qinfo[0], qinfo[1], local_bound) self.ser.addOperator(op["op"], input_list, output_list, attr) return result_tens @@ -1011,8 +1017,13 @@ class TosaTestGen: ): return None + # TODO - Test local_bound, for now set local bound attribute to False + local_bound = False + attr = ts.TosaSerializerAttribute() - attr.TransposeConvAttribute(out_pad, stride, output_shape, qinfo[0], qinfo[1]) + attr.TransposeConvAttribute( + out_pad, stride, output_shape, qinfo[0], qinfo[1], local_bound + ) self.ser.addOperator(op["op"], input_list, output_list, attr) return result_tens @@ -1084,8 +1095,11 @@ class TosaTestGen: ): return None + # TODO - Test local_bound, for now set local bound attribute to False + local_bound = False + attr = ts.TosaSerializerAttribute() - attr.ConvAttribute(padding, strides, dilations, qinfo[0], qinfo[1]) + attr.ConvAttribute(padding, strides, dilations, qinfo[0], qinfo[1], local_bound) self.ser.addOperator(op["op"], input_list, output_list, attr) return result_tens @@ -2394,7 +2408,13 @@ class TosaTestGen: return acc_out def build_fft2d( - self, op, val1, val2, inverse, validator_fcns=None, error_name=None + self, + op, + val1, + val2, + inverse, + validator_fcns=None, + error_name=None, ): results = OutputShaper.fft2dOp(self.ser, self.rng, val1, val2, error_name) @@ -2429,13 +2449,22 @@ class TosaTestGen: ): return None + # TODO - Test local_bound, for now set local bound attribute to False + local_bound = False + attr = ts.TosaSerializerAttribute() - attr.FFTAttribute(inverse) + attr.FFTAttribute(inverse, local_bound) self.ser.addOperator(op["op"], input_names, output_names, attr) return results - def build_rfft2d(self, op, val, validator_fcns=None, error_name=None): + def build_rfft2d( + self, + op, + val, + validator_fcns=None, + error_name=None, + ): results = OutputShaper.rfft2dOp(self.ser, self.rng, val, error_name) input_names = [val.name] @@ -2466,7 +2495,13 @@ class TosaTestGen: ): return None - self.ser.addOperator(op["op"], input_names, output_names) + # TODO - Test local_bound, for now set local bound attribute to False + local_bound = False + + attr = ts.TosaSerializerAttribute() + attr.RFFTAttribute(local_bound) + + self.ser.addOperator(op["op"], input_names, output_names, attr) return results def create_filter_lists( |