Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider adding int64/uint64 data type support for some reduce operators #694

Open
lisa0314 opened this issue May 27, 2024 · 1 comment
Open
Assignees

Comments

@lisa0314
Copy link

One safety checker SD model failed since 'reduceSum' which from Safety Checker requires int64 input type. And currently, WebNN spec only supports int32, uint32, float32 and float16 for reduceSum.

image

I suppose we should add int64 and uint64 data type for ReduceSum, ReduceSumSquare, ReduceProduct and ReduceL1 which is consistent with DirectML reduce operation definition:
https://learn.microsoft.com/en-us/windows/win32/api/directml/ns-directml-dml_reduce_operator_desc#multiply-and-sum and https://learn.microsoft.com/en-us/windows/win32/api/directml/ns-directml-dml_reduce_operator_desc#l1-and-sum_square.

huningxin added a commit to huningxin/webnn that referenced this issue May 27, 2024
`reduceL1`, `reduceProduct`, `reduceSum` and `reduceSumSquare` support
already 32-bit integers. 64-bit integers should also be supported.

Fix webmachinelearning#283, webmachinelearning#694
huningxin added a commit to huningxin/webnn that referenced this issue May 27, 2024
`reduceL1`, `reduceProduct`, `reduceSum` and `reduceSumSquare` already
support 32-bit integers. 64-bit integers should also be supported.

Fix webmachinelearning#283, webmachinelearning#694
@anssiko
Copy link
Member

anssiko commented Nov 7, 2024

Discussed on 2024-10-31: int64/uint64 data type support to be consider together with device selection to find the right abstraction.

@huningxin perhaps convert PR #695 to a draft meanwhile?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants