The Concat operation does not properly compare typings (line 15), resulting in an excess of redundant Cast operations.
It will return False when the input and output tensors are the same type but of different sizes (which is most of the use cases of the Concat operation)
For example,
Int64TensorType(shape=[None, 1]) == Int64TensorType(shape=[None, 10])
returns False, resulting in an extra cast operation on each of the 10 Int64 inputs.
https://github.com/onnx/sklearn-onnx/blob/7bfcd523b00c0043437387d17e23438fd5713eee/skl2onnx/operator_converters/concat_op.py#L12-L22
The Concat operation does not properly compare typings (line 15), resulting in an excess of redundant Cast operations. It will return False when the input and output tensors are the same type but of different sizes (which is most of the use cases of the Concat operation)
For example,
Int64TensorType(shape=[None, 1]) == Int64TensorType(shape=[None, 10])
returns False, resulting in an extra cast operation on each of the 10 Int64 inputs.