slyubomirsky commented on code in PR #14324:
URL: https://github.com/apache/tvm/pull/14324#discussion_r1140470028
##########
tests/python/relax/test_op_index.py:
##########
@@ -376,22 +409,22 @@ def test_strided_slice_infer_struct_info_shape_symbolic():
_check_inference(
bb,
relax.op.strided_slice(x0, axes=[0], begin=[1], end=[3]),
- relax.TensorStructInfo((2, n), "float32"),
+ relax.TensorStructInfo((tir.min(3, m) - tir.min(1, m) + 1 - 1, n),
"float32"),
Review Comment:
Oh I see, that's what the question was getting at. So if `m` is not 2, would
the current implementation give an error? If we require that, perhaps
`FInferStructInfo` should assert that `m` is 2 and require a `MatchCast`
beforehand. I don't think we should allow for shape mismatch errors to happen
"silently" (have the StructInfo system accept the program without any explicit
casts but then fail at runtime)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]