Skip to content

[Fix][Relax][Frontend][Torch] Register prod.dim_int in the exported program converter - #21014

Open
SAY-5 wants to merge 1 commit into
apache:mainfrom
SAY-5:fix-prod-dim-int-export
Open

SAY-5 wants to merge 1 commit into
apache:mainfrom
SAY-5:fix-prod-dim-int-export

Conversation

@SAY-5

@SAY-5 SAY-5 commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

Fixes: #20948

torch.prod(x, dim=...) exports as aten.prod.dim_int, which had no entry in the exported program convert map, so from_exported_program failed with Unsupported function types ['prod.dim_int']. _prod already reads dim and keepdim, so this registers the overload and adds a test for both. I couldn't build main locally, so I ran the new test against the 0.27.0 release with the same one-line change (fails before, passes after) and checked the compiled output against torch.

…rogram converter

Signed-off-by: Sai Asish Y <say.apm35@gmail.com>

This branch has not been deployed

No deployments
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.

[Bug][Relax][PyTorch] torch.prod with reduction dimension fails in from_exported_program: "AssertionError: Unsupported function types ['prod.dim_int']"

1 participant