You are viewing a plain text version of this content. The canonical link for it is here.
Posted to discuss-archive@tvm.apache.org by "hahalfx (via GitHub)" <gi...@apache.org> on 2026/08/05 07:21:11 UTC

[PR] [Fix][Relax][ONNX] Handle Split initializer with keep_params_in_input [tvm]

hahalfx opened a new pull request, #20091:
URL: https://github.com/apache/tvm/pull/20091

   Fixes #20066.
   
   When `keep_params_in_input=True`, ONNX initializers are represented as
   Relax function parameters while their values remain in the importer
   parameter map. `Split._impl_v13` only accepted `relax.Constant`, so it
   incorrectly rejected a static initializer as a dynamic Split input.
   
   This change resolves the Split input through the existing `get_constant`
   helper before computing the split indices. Genuinely dynamic Split inputs
   remain unsupported and continue to raise the existing error.
   
   The regression test imports an opset-13 model with initializer-backed split
   sizes and verifies both the stored parameter value and the generated Relax IR.
   
   ### Testing
   
   - `cmake --build build --parallel 8`
   - `python -m pytest tests/python/relax/test_frontend_onnx.py::test_split_initializer_with_params_in_input tests/python/relax/test_frontend_onnx.py::test_split -xvs` — 2 passed
   - `pre-commit run --files python/tvm/relax/frontend/onnx/onnx_frontend.py tests/python/relax/test_frontend_onnx.py`


-- 
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: discuss-archive-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: discuss-archive-unsubscribe@tvm.apache.org
For additional commands, e-mail: discuss-archive-help@tvm.apache.org


Re: [PR] [Fix][Relax][ONNX] Handle Split initializer with keep_params_in_input [tvm]

Posted by "tlopex (via GitHub)" <gi...@apache.org>.
tlopex merged PR #20091:
URL: https://github.com/apache/tvm/pull/20091


-- 
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: discuss-archive-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: discuss-archive-unsubscribe@tvm.apache.org
For additional commands, e-mail: discuss-archive-help@tvm.apache.org