We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 16826a6 commit cf7c56eCopy full SHA for cf7c56e
src/qonnx/transformation/channels_last.py
@@ -301,7 +301,10 @@ def apply(self, model):
301
ndim = len(input_shape)
302
if list(to_channels_first_args(ndim)) == perm_1:
303
successor_nodes = model.find_direct_successors(n)
304
- if successor_nodes is None:
+ # skip if:
305
+ # - this Transpose has no successors (nothing to do)
306
+ # - this Transpose output is forking (cannot remove)
307
+ if successor_nodes is None or len(successor_nodes) > 1:
308
continue
309
successor_node = successor_nodes[0]
310
0 commit comments