aboutsummaryrefslogtreecommitdiff
path: root/reference_model/src/ops/op_factory.h
diff options
context:
space:
mode:
authorEric Kunze <eric.kunze@arm.com>2022-06-07 05:20:44 +0000
committerEric Kunze <eric.kunze@arm.com>2022-06-15 11:38:04 -0700
commitb5fabec33abeca2d92c20c7b094fa3f113d0ddd8 (patch)
tree9c7d946012c7a70a7fcb237daa4376d7b65c6f76 /reference_model/src/ops/op_factory.h
parent24594f55ee3bf0e95c764e51b94c3ec7f9cfa54a (diff)
downloadreference_model-b5fabec33abeca2d92c20c7b094fa3f113d0ddd8.tar.gz
Remove quantization info from serialization attributes
Any needed information moves into the attributes for each operator. New serialization library version removes teh quantization information attributes from the schema Signed-off-by: Eric Kunze <eric.kunze@arm.com> Change-Id: Icf6165687ab1fd34a01f64c01b0b92b2820e72fa
Diffstat (limited to 'reference_model/src/ops/op_factory.h')
-rw-r--r--reference_model/src/ops/op_factory.h30
1 files changed, 14 insertions, 16 deletions
diff --git a/reference_model/src/ops/op_factory.h b/reference_model/src/ops/op_factory.h
index eaa359c..4cb8178 100644
--- a/reference_model/src/ops/op_factory.h
+++ b/reference_model/src/ops/op_factory.h
@@ -18,61 +18,60 @@
#include "attribute.h"
#include "graph_node.h"
-#include "quant_info.h"
#include "template_types.h"
#include "tosa_serialization_handler.h"
#define DEF_FACTORY_ONE_RANK_ONE_TYPE(OP, RANK, DTYPE) \
case RANK: \
- return new OP<RANK, DType_##DTYPE>(sgt, attribute, qinfo, id);
+ return new OP<RANK, DType_##DTYPE>(sgt, attribute, id);
#define DEF_FACTORY_ONE_RANK_TWO_TYPE(OP, RANK, DTYPE1, DTYPE2) \
case RANK: \
- return new OP<RANK, DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, qinfo, id);
+ return new OP<RANK, DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, id);
#define DEF_FACTORY_TWO_RANK_ONE_TYPE(OP, RANK1, RANK2, DTYPE) \
case RANK2: \
- return new OP<RANK1, RANK2, DType_##DTYPE>(sgt, attribute, qinfo, id);
+ return new OP<RANK1, RANK2, DType_##DTYPE>(sgt, attribute, id);
#define DEF_FACTORY_TWO_RANK_TWO_TYPE(OP, RANK1, RANK2, DTYPE1, DTYPE2) \
case RANK2: \
- return new OP<RANK1, RANK2, DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, qinfo, id);
+ return new OP<RANK1, RANK2, DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, id);
#define DEF_FACTORY_ONE_RANK_0_6(OP) \
switch (inputRank) \
{ \
case 0: \
- return new OP<0>(sgt, attribute, qinfo, id); \
+ return new OP<0>(sgt, attribute, id); \
case 1: \
- return new OP<1>(sgt, attribute, qinfo, id); \
+ return new OP<1>(sgt, attribute, id); \
case 2: \
- return new OP<2>(sgt, attribute, qinfo, id); \
+ return new OP<2>(sgt, attribute, id); \
case 3: \
- return new OP<3>(sgt, attribute, qinfo, id); \
+ return new OP<3>(sgt, attribute, id); \
case 4: \
- return new OP<4>(sgt, attribute, qinfo, id); \
+ return new OP<4>(sgt, attribute, id); \
case 5: \
- return new OP<5>(sgt, attribute, qinfo, id); \
+ return new OP<5>(sgt, attribute, id); \
case 6: \
- return new OP<6>(sgt, attribute, qinfo, id); \
+ return new OP<6>(sgt, attribute, id); \
}
#define DEF_FACTORY_ONE_TYPE(OP, DTYPE) \
if (inputDType == DType_##DTYPE) \
{ \
- return new OP<DType_##DTYPE>(sgt, attribute, qinfo, id); \
+ return new OP<DType_##DTYPE>(sgt, attribute, id); \
}
#define DEF_FACTORY_TWO_TYPE(OP, DTYPE1, DTYPE2) \
if (inputDType == DType_##DTYPE1 && weightDType == DType_##DTYPE2) \
{ \
- return new OP<DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, qinfo, id); \
+ return new OP<DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, id); \
}
#define DEF_FACTORY_TWO_TYPE_RESIZE(OP, DTYPE1, DTYPE2) \
if (inputDType == DType_##DTYPE1 && outputDType == DType_##DTYPE2) \
{ \
- return new OP<DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, qinfo, id); \
+ return new OP<DType_##DTYPE1, DType_##DTYPE2>(sgt, attribute, id); \
}
#define DEF_FACTORY_RANK0_6_ONE_RANK_ONE_TYPE(OP, DTYPE) \
@@ -231,7 +230,6 @@ public:
tosa::TosaSerializationHandler* tsh,
tosa::Op opType,
tosa::TosaAttributeBase* attribute,
- tosa::TosaQuantInfoBase* qinfo,
uint64_t id,
tosa::DType inputDType,
int inputRank,