diff options
author | Tim Hall <tim.hall@arm.com> | 2020-08-04 19:00:48 +0100 |
---|---|---|
committer | tim.hall <tim.hall@arm.com> | 2020-08-19 17:45:51 +0000 |
commit | b16dccec7e03a24f99e63667340696c7fc880d43 (patch) | |
tree | e16f5e451fa6dfc8ee41430671c2c8af96bf3aab /ethosu/vela | |
parent | e5b01638d78062f96f6560a9ab632db99f2213a6 (diff) | |
download | ethos-u-vela-b16dccec7e03a24f99e63667340696c7fc880d43.tar.gz |
vela: Minor refactor of operation class
- Removed some of the clutter
Signed-off-by: Tim Hall <tim.hall@arm.com>
Change-Id: I9a12f681247befd44dbbc9d7fbd135f0603d2fbd
Diffstat (limited to 'ethosu/vela')
-rw-r--r-- | ethosu/vela/operation.py | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/ethosu/vela/operation.py b/ethosu/vela/operation.py index 0290e811..3b34fe81 100644 --- a/ethosu/vela/operation.py +++ b/ethosu/vela/operation.py @@ -179,10 +179,8 @@ input and output tensors, as well as an attribute dictionary.""" return ifm_tensor, weight_tensor, bias_tensor, ofm_tensor - concat_ops = set(("Concat", "ConcatV2", "QuantizedConcat", "ConcatTFLite", "PackReshaped")) - def is_concat_op(self): - return self.type in Operation.concat_ops + return self.type in set(("Concat", "ConcatV2", "QuantizedConcat", "ConcatTFLite", "PackReshaped")) def get_concat_inputs_axis(self): assert self.is_concat_op() @@ -216,10 +214,8 @@ input and output tensors, as well as an attribute dictionary.""" _, dilation_h, dilation_w, _ = self.attrs.get("dilation", (1, 1, 1, 1)) return dilation_h, dilation_w - split_ops = set(("Split", "SplitV", "StridedSlice", "Slice", "UnpackReshaped")) - def is_split_op(self): - return self.type in Operation.split_ops + return self.type in set(("Split", "SplitV", "StridedSlice", "Slice", "UnpackReshaped")) def get_split_inputs_axis(self): assert self.is_split_op() |