Skip to content

fix(onnx): treat empty Resize axes as no-op - #39197

Open
YugShah1510 wants to merge 1 commit into
openvinotoolkit:masterfrom
YugShah1510:codex/onnx-edgecase-fix
Open

YugShah1510 wants to merge 1 commit into
openvinotoolkit:masterfrom
YugShah1510:codex/onnx-edgecase-fix

Conversation

@YugShah1510

Copy link
Copy Markdown
Contributor

What changed

ONNX Resize distinguishes an omitted axes attribute (resize all dimensions) from an explicitly empty axes list (resize no dimensions). The frontend previously treated both as omitted and attempted to construct an all-axes Interpolate with an empty scale vector, causing valid models to fail shape validation.

When axes is present and empty, return the data output directly. Add an opset 18 regression test using a zero-length scales input and assert that the output equals the input.

Fixes #39196

Validation

  • python3 -m py_compile src/frontends/onnx/tests/tests_python/test_ops_resize.py — passed.
  • git diff --cached --check — passed before commit.
  • Focused pytest could not run: pytest is not installed in this environment.
  • Runtime reproduction/build could not run: the onnx Python package is not installed and this worktree has no configured build directory.

@YugShah1510
YugShah1510 requested a review from a team as a code owner October 25, 2026 14:50
@github-actions github-actions Bot added the category: ONNX FE OpenVINO ONNX FrontEnd label Oct 25, 2026
@sys-openvino-ci sys-openvino-ci added the ExternalPR External contributor label Oct 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: ONNX FE OpenVINO ONNX FrontEnd ExternalPR External contributor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ONNX FE] Resize with an explicitly empty axes attribute fails instead of acting as a no-op

2 participants