This is the root cause to many issues. When symbolic shape is involved in torch.listconstruct, instead of a CoreML tensor, we simply return the list as is
def _array_construct(context, node, array_type):
...
else:
# If at least one input to the construct op is non-const, collect
# the inputs and add them directly to the context. Ops that use this
# node's output will take the list directly as input.
context.add(array_type(inputs), node.name)
This is the root cause to many issues. When symbolic shape is involved in
torch.listconstruct, instead of a CoreML tensor, we simply return the list as isAppendix 1: Issues Sharing the Same Root Cause
Appendix 2: Ops Impacted by the Root Cause
torch.GroupNormtorch.padtorch.index_put