Skip to content

Update Flatten CUDA operator to fill opset gap (13 → 25)#27736

Closed
Copilot wants to merge 1 commit intomainfrom
copilot/update-flatten-cuda-operator
Closed

Update Flatten CUDA operator to fill opset gap (13 → 25)#27736
Copilot wants to merge 1 commit intomainfrom
copilot/update-flatten-cuda-operator

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 18, 2026

Description

Extends CUDA Flatten kernel registration from opset 13 through opset 25, following the same pattern used for other operators (ConstantOfShape, Identity, If, Loop, Scan, Size) in #27728.

  • flatten.cc: Split single opset-13 registration into versioned ranges 13–20, 21–22, 23–24, and final 25
  • cuda_execution_provider.cc: Added corresponding forward declarations and function table entries for each new opset range

No logic or type constraint changes — Flatten is a pure reshape, so the kernel implementation is identical across all opset versions.

Motivation and Context

CUDA Flatten was registered only at opset 13 while ONNX defines it through opset 25 (a 12-opset gap). This causes models exported at newer opsets to fall back from the CUDA EP. See #27729.

Co-authored-by: tianleiwu <30328909+tianleiwu@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants