diff options
author | Patrik Gustavsson <patrik.gustavsson@arm.com> | 2020-04-30 08:57:23 +0200 |
---|---|---|
committer | Tim Hall <tim.hall@arm.com> | 2020-06-18 17:53:52 +0100 |
commit | cf72890e5dd89dada3189816a61d174b984086bd (patch) | |
tree | 5693bf04ed8a1d5084ff521163b54a2730ef3917 /ethosu/vela/operation.py | |
parent | 0538a77dfe65b66efedc4e4b92d851a5aeb46ea4 (diff) | |
download | ethos-u-vela-cf72890e5dd89dada3189816a61d174b984086bd.tar.gz |
MLBEDSW-1998: Add support for new_axis_mask
-Added support for new_axis_mask
-Added support for more than 1 bit set in new/shrink_axis mask
-Added checks for strided slice in supported operator check
-Added assert if nothing has been put on NPU
Change-Id: I66e2d04784f14d7ad82371f5d649a455d576a818
Signed-off-by: Patrik Gustavsson <patrik.gustavsson@arm.com>
Diffstat (limited to 'ethosu/vela/operation.py')
-rw-r--r-- | ethosu/vela/operation.py | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/ethosu/vela/operation.py b/ethosu/vela/operation.py index f36e61c6..a25574a6 100644 --- a/ethosu/vela/operation.py +++ b/ethosu/vela/operation.py @@ -248,12 +248,10 @@ input and output tensors, as well as an attribute dictionary.""" end_mask = self.attrs["end_mask"] new_axis_mask = self.attrs["new_axis_mask"] shrink_axis_mask = self.attrs["shrink_axis_mask"] - # TODO: Either extend this to support these different masks or check - # for this at an earlier stage and place the op on Cpu if needed - assert new_axis_mask == ellipsis_mask == 0 - # shrink_axis_mask is not supported by the Operation class but the operation + + # shrink_axis_mask/new_axis_mask/ellipsis_mask is not supported by the Operation class but the operation # may have the attribute modified and handled in the graph optimization phase. - assert shrink_axis_mask == 0 + assert shrink_axis_mask == new_axis_mask == ellipsis_mask == 0 assert len(input_tens.shape) == len(out_tens.shape) for idx in range(len(input_tens.shape)): |