Rename pool2d MLRoundingType - Simplify the operand layout support of conv2d and pooling 2d operations - #770
Conversation
| 1. If any value in |options|.{{MLPool2dOptions/dilations}} is not greater than 0, then [=exception/throw=] a {{TypeError}}. | ||
| 1. Let |desc| be a copy of |input|.{{MLOperand/[[descriptor]]}}. | ||
| 1. Let |outputShape| be the result of [=MLGraphBuilder/calculating pool2d output sizes=] given |options|.{{MLPool2dOptions/layout}}, |input|'s [=MLOperand/shape=], |options|.{{MLPool2dOptions/roundingType}}, |options|.{{MLPool2dOptions/windowDimensions}}, |options|.{{MLPool2dOptions/padding}}, |options|.{{MLPool2dOptions/strides}}, |options|.{{MLPool2dOptions/dilations}}, and |options|.{{MLPool2dOptions/outputSizes}} (if it [=map/exists=]). | ||
| 1. Let |outputShape| be the result of [=MLGraphBuilder/calculating pool2d output sizes=] given |options|.{{MLPool2dOptions/layout}}, |input|'s [=MLOperand/shape=], |options|.{{MLPool2dOptions/windowDimensions}}, |options|.{{MLPool2dOptions/padding}}, |options|.{{MLPool2dOptions/strides}}, |options|.{{MLPool2dOptions/dilations}}, and |options|.{{MLPool2dOptions/outputSizes}} (if it [=map/exists=]). |
There was a problem hiding this comment.
The outputSizes validation above in 13.2 doesn't appear to be correct--shouldn't it be similar to this logic?
There was a problem hiding this comment.
I think this is now resolved by Joshua?
|
This implicitly resolves #374 as well, doesn't it? |
|
This PR needs a redo since there's been a lot of spec churn since Nov 2024. But one thing I noticed in the current spec text:
That implies that if outputSizes becomes a required option, then any passed padding will always be ignored. Flaw in the current text? I think the first clause "if options.outputSizes exists" is bogus today, and should be removed. |
|
I'm confused by the build errors, as I didn't touch any of those lines, and |
|
the build error is indeed unrelated to the particular change, but linked to the definition set bikeshed uses for auto-linking. the simplest short term solution is to add |
@huningxin: Any changes desired? |
| 1. If |options|.{{MLPool2dOptions/outputSizes}} [=map/exists=], then: | ||
| 1. Let « |outputHeight|, |outputWidth| » be |options|.{{MLPool2dOptions/outputSizes}}. | ||
| 1. Let « |outputHeight|, |outputWidth| » be |options|.{{MLPool2dOptions/outputSizes}}. | ||
| 1. If neither |outputHeight| equals floor( |calculatedOutputHeight| ) and |outputWidth| equals floor( |calculatedOutputWidth| ), nor |outputHeight| equals ceil( |calculatedOutputHeight| ) and |outputWidth| equals ceil( |calculatedOutputWidth| ), then [=exception/throw=] a {{TypeError}}. |
There was a problem hiding this comment.
And this line should also indent.
There was a problem hiding this comment.
True. I was thinking it would just fall through safely, but it's unnecessary to check this condition because we already know that calculating conv2d output sizes computing legal sizes.
This CL renames MLPool2dOptions::roundingType to MLPool2dOptions::outputShapeRounding in test files and implementations according to Spec change [1]. [1] webmachinelearning/webnn#770 Bug: 498118207 Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 Cq-Include-Trybots: luci.chromium.try:win11-blink-rel, mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
This CL renames MLPool2dOptions::roundingType to MLPool2dOptions::outputShapeRounding in test files and implementations according to Spec change [1]. [1] webmachinelearning/webnn#770 Bug: 498118207 Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
This CL renames MLPool2dOptions::roundingType to MLPool2dOptions::outputShapeRounding in test files and implementations according to Spec change [1]. [1] webmachinelearning/webnn#770 Bug: 498118207 Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> Reviewed-by: Reilly Grant <reillyg@chromium.org> Reviewed-by: Alex Gough <ajgo@chromium.org> Auto-Submit: Dai, Feng <feng.dai@intel.com> Commit-Queue: Dai, Feng <feng.dai@intel.com> Cr-Commit-Position: refs/heads/main@{#1618021}
This CL renames MLPool2dOptions::roundingType to MLPool2dOptions::outputShapeRounding in test files and implementations according to Spec change [1]. [1] webmachinelearning/webnn#770 Bug: 498118207 Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> Reviewed-by: Reilly Grant <reillyg@chromium.org> Reviewed-by: Alex Gough <ajgo@chromium.org> Auto-Submit: Dai, Feng <feng.dai@intel.com> Commit-Queue: Dai, Feng <feng.dai@intel.com> Cr-Commit-Position: refs/heads/main@{#1618021}
This CL renames MLPool2dOptions::roundingType to MLPool2dOptions::outputShapeRounding in test files and implementations according to Spec change [1]. [1] webmachinelearning/webnn#770 Bug: 498118207 Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> Reviewed-by: Reilly Grant <reillyg@chromium.org> Reviewed-by: Alex Gough <ajgo@chromium.org> Auto-Submit: Dai, Feng <feng.dai@intel.com> Commit-Queue: Dai, Feng <feng.dai@intel.com> Cr-Commit-Position: refs/heads/main@{#1618021}
…ops" This reverts commit e581146. Reason for revert: LUCI Bisection has identified this change as the cause of a test failure. See the analysis: https://ci.chromium.org/ui/p/chromium/bisection/test-analysis/b/6349833846652928 Sample build with failed test: https://ci.chromium.org/b/8683829578450763649 Affected test(s): [://\:blink_wpt_tests!webtest::virtual/webnn-service-on-cpu/external/wpt/webnn/conformance_tests#averagePool2d.https.any.html?cpu](https://ci.chromium.org/ui/test/chromium/:%2F%2F%5C:blink_wpt_tests%21webtest::virtual%2Fwebnn-service-on-cpu%2Fexternal%2Fwpt%2Fwebnn%2Fconformance_tests%23averagePool2d.https.any.html%3Fcpu?q=VHash%3A2dc5f607fec8a763) [://\:blink_wpt_tests!webtest::virtual/webnn-service-on-cpu/external/wpt/webnn/conformance_tests#maxPool2d.https.any.html?cpu](https://ci.chromium.org/ui/test/chromium/:%2F%2F%5C:blink_wpt_tests%21webtest::virtual%2Fwebnn-service-on-cpu%2Fexternal%2Fwpt%2Fwebnn%2Fconformance_tests%23maxPool2d.https.any.html%3Fcpu?q=VHash%3A2dc5f607fec8a763) If this is a false positive, please report it at http://b.corp.google.com/createIssue?component=1199205&description=Analysis%3A+https%3A%2F%2Fci.chromium.org%2Fui%2Fp%2Fchromium%2Fbisection%2Ftest-analysis%2Fb%2F6349833846652928&format=PLAIN&priority=P3&title=Wrongly+blamed+https%3A%2F%2Fchromium-review.googlesource.com%2Fc%2Fchromium%2Fsrc%2F%2B%2F7717139&type=BUG Original change's description: > webnn: rename roundingType to outputShapeRounding for pool2d ops > > This CL renames MLPool2dOptions::roundingType to > MLPool2dOptions::outputShapeRounding in test files and implementations > according to Spec change [1]. > > [1] webmachinelearning/webnn#770 > > Bug: 498118207 > Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 > Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 > Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> > Reviewed-by: Reilly Grant <reillyg@chromium.org> > Reviewed-by: Alex Gough <ajgo@chromium.org> > Auto-Submit: Dai, Feng <feng.dai@intel.com> > Commit-Queue: Dai, Feng <feng.dai@intel.com> > Cr-Commit-Position: refs/heads/main@{#1618021} > Bug: 498118207 No-Presubmit: true No-Tree-Checks: true No-Try: true Change-Id: I492d6269e88cfb4b65a22f495a2b73a1168c7747 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7783895 Reviewed-by: Alex Gough <ajgo@chromium.org> Owners-Override: Adem Derinel <derinel@google.com> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> Commit-Queue: Adem Derinel <derinel@google.com> Reviewed-by: Adem Derinel <derinel@google.com> Cr-Commit-Position: refs/heads/main@{#1618876}
…ops" This reverts commit e5811467122a07253805711cf7331c2de1741f1d. Reason for revert: LUCI Bisection has identified this change as the cause of a test failure. See the analysis: https://ci.chromium.org/ui/p/chromium/bisection/test-analysis/b/6349833846652928 Sample build with failed test: https://ci.chromium.org/b/8683829578450763649 Affected test(s): [://\:blink_wpt_tests!webtest::virtual/webnn-service-on-cpu/external/wpt/webnn/conformance_tests#averagePool2d.https.any.html?cpu](https://ci.chromium.org/ui/test/chromium/:%2F%2F%5C:blink_wpt_tests%21webtest::virtual%2Fwebnn-service-on-cpu%2Fexternal%2Fwpt%2Fwebnn%2Fconformance_tests%23averagePool2d.https.any.html%3Fcpu?q=VHash%3A2dc5f607fec8a763) [://\:blink_wpt_tests!webtest::virtual/webnn-service-on-cpu/external/wpt/webnn/conformance_tests#maxPool2d.https.any.html?cpu](https://ci.chromium.org/ui/test/chromium/:%2F%2F%5C:blink_wpt_tests%21webtest::virtual%2Fwebnn-service-on-cpu%2Fexternal%2Fwpt%2Fwebnn%2Fconformance_tests%23maxPool2d.https.any.html%3Fcpu?q=VHash%3A2dc5f607fec8a763) If this is a false positive, please report it at http://b.corp.google.com/createIssue?component=1199205&description=Analysis%3A+https%3A%2F%2Fci.chromium.org%2Fui%2Fp%2Fchromium%2Fbisection%2Ftest-analysis%2Fb%2F6349833846652928&format=PLAIN&priority=P3&title=Wrongly+blamed+https%3A%2F%2Fchromium-review.googlesource.com%2Fc%2Fchromium%2Fsrc%2F%2B%2F7717139&type=BUG Original change's description: > webnn: rename roundingType to outputShapeRounding for pool2d ops > > This CL renames MLPool2dOptions::roundingType to > MLPool2dOptions::outputShapeRounding in test files and implementations > according to Spec change [1]. > > [1] webmachinelearning/webnn#770 > > Bug: 498118207 > Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 > Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 > Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> > Reviewed-by: Reilly Grant <reillyg@chromium.org> > Reviewed-by: Alex Gough <ajgo@chromium.org> > Auto-Submit: Dai, Feng <feng.dai@intel.com> > Commit-Queue: Dai, Feng <feng.dai@intel.com> > Cr-Commit-Position: refs/heads/main@{#1618021} > Bug: 498118207 No-Presubmit: true No-Tree-Checks: true No-Try: true Change-Id: I492d6269e88cfb4b65a22f495a2b73a1168c7747 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7783895 Reviewed-by: Alex Gough <ajgo@chromium.org> Owners-Override: Adem Derinel <derinel@google.com> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> Commit-Queue: Adem Derinel <derinel@google.com> Reviewed-by: Adem Derinel <derinel@google.com> Cr-Commit-Position: refs/heads/main@{#1618876}
…eRounding for pool2d ops, a=testonly Automatic update from web-platform-tests webnn: rename roundingType to outputShapeRounding for pool2d ops This CL renames MLPool2dOptions::roundingType to MLPool2dOptions::outputShapeRounding in test files and implementations according to Spec change [1]. [1] webmachinelearning/webnn#770 Bug: 498118207 Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> Reviewed-by: Reilly Grant <reillyg@chromium.org> Reviewed-by: Alex Gough <ajgo@chromium.org> Auto-Submit: Dai, Feng <feng.dai@intel.com> Commit-Queue: Dai, Feng <feng.dai@intel.com> Cr-Commit-Position: refs/heads/main@{#1618021} -- wpt-commits: 1654471ad9b5ff35861d80d3d40cce113c6acb9d wpt-pr: 59145
…tputShapeRounding for pool2d ops", a=testonly Automatic update from web-platform-tests Revert "webnn: rename roundingType to outputShapeRounding for pool2d ops" This reverts commit e5811467122a07253805711cf7331c2de1741f1d. Reason for revert: LUCI Bisection has identified this change as the cause of a test failure. See the analysis: https://ci.chromium.org/ui/p/chromium/bisection/test-analysis/b/6349833846652928 Sample build with failed test: https://ci.chromium.org/b/8683829578450763649 Affected test(s): [://\:blink_wpt_tests!webtest::virtual/webnn-service-on-cpu/external/wpt/webnn/conformance_tests#averagePool2d.https.any.html?cpu](https://ci.chromium.org/ui/test/chromium/:%2F%2F%5C:blink_wpt_tests%21webtest::virtual%2Fwebnn-service-on-cpu%2Fexternal%2Fwpt%2Fwebnn%2Fconformance_tests%23averagePool2d.https.any.html%3Fcpu?q=VHash%3A2dc5f607fec8a763) [://\:blink_wpt_tests!webtest::virtual/webnn-service-on-cpu/external/wpt/webnn/conformance_tests#maxPool2d.https.any.html?cpu](https://ci.chromium.org/ui/test/chromium/:%2F%2F%5C:blink_wpt_tests%21webtest::virtual%2Fwebnn-service-on-cpu%2Fexternal%2Fwpt%2Fwebnn%2Fconformance_tests%23maxPool2d.https.any.html%3Fcpu?q=VHash%3A2dc5f607fec8a763) If this is a false positive, please report it at http://b.corp.google.com/createIssue?component=1199205&description=Analysis%3A+https%3A%2F%2Fci.chromium.org%2Fui%2Fp%2Fchromium%2Fbisection%2Ftest-analysis%2Fb%2F6349833846652928&format=PLAIN&priority=P3&title=Wrongly+blamed+https%3A%2F%2Fchromium-review.googlesource.com%2Fc%2Fchromium%2Fsrc%2F%2B%2F7717139&type=BUG Original change's description: > webnn: rename roundingType to outputShapeRounding for pool2d ops > > This CL renames MLPool2dOptions::roundingType to > MLPool2dOptions::outputShapeRounding in test files and implementations > according to Spec change [1]. > > [1] webmachinelearning/webnn#770 > > Bug: 498118207 > Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 > Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 > Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> > Reviewed-by: Reilly Grant <reillyg@chromium.org> > Reviewed-by: Alex Gough <ajgo@chromium.org> > Auto-Submit: Dai, Feng <feng.dai@intel.com> > Commit-Queue: Dai, Feng <feng.dai@intel.com> > Cr-Commit-Position: refs/heads/main@{#1618021} > Bug: 498118207 No-Presubmit: true No-Tree-Checks: true No-Try: true Change-Id: I492d6269e88cfb4b65a22f495a2b73a1168c7747 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7783895 Reviewed-by: Alex Gough <ajgo@chromium.org> Owners-Override: Adem Derinel <derinel@google.com> Bot-Commit: rubber-stamper@appspot.gserviceaccount.com <rubber-stamper@appspot.gserviceaccount.com> Commit-Queue: Adem Derinel <derinel@google.com> Reviewed-by: Adem Derinel <derinel@google.com> Cr-Commit-Position: refs/heads/main@{#1618876} -- wpt-commits: b7feb889720d87f1239591a959703cfa2d15f226 wpt-pr: 59407
…8172) Keep original roundingType name for a period of time to ensure backward compatibility. Spec change: webmachinelearning/webnn#770 --------- Co-authored-by: Dwayne Robinson <fdwr@hotmail.com>
…ops" This is a reland of commit e581146. The original CL was reverted because two newly-added baseline files under platform/win11-arm64/virtual/webnn-service-on-cpu/... still referenced the old "roundingType" test names, which no longer matched the renamed WPT cases ("outputShapeRounding"). Those baselines are updated in this reland. Original change's description: > webnn: rename roundingType to outputShapeRounding for pool2d ops > > This CL renames MLPool2dOptions::roundingType to > MLPool2dOptions::outputShapeRounding in test files and implementations > according to Spec change [1]. > > [1] webmachinelearning/webnn#770 > > Bug: 498118207 > Change-Id: I815c7f7728071144835c0ada0747bc9de2999669 > Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139 > Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> > Reviewed-by: Reilly Grant <reillyg@chromium.org> > Reviewed-by: Alex Gough <ajgo@chromium.org> > Auto-Submit: Dai, Feng <feng.dai@intel.com> > Commit-Queue: Dai, Feng <feng.dai@intel.com> > Cr-Commit-Position: refs/heads/main@{#1618021} Bug: 498118207 Change-Id: I4df2860081223af43493a0447ca5e69e104950df Cq-Include-Trybots: luci.chromium.try:win11-blink-rel, win11-arm64-blink-rel, mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7882018 Reviewed-by: Joe Mason <joenotcharles@google.com> Reviewed-by: Reilly Grant <reillyg@chromium.org> Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com> Commit-Queue: Dai, Feng <feng.dai@intel.com> Reviewed-by: Elias Klim <elklm@chromium.org> Cr-Commit-Position: refs/heads/main@{#1639919}
…ops"
This is a reland of commit e5811467122a07253805711cf7331c2de1741f1d.
The original CL was reverted because two newly-added baseline files
under platform/win11-arm64/virtual/webnn-service-on-cpu/... still
referenced the old "roundingType" test names, which no longer matched
the renamed WPT cases ("outputShapeRounding"). Those baselines are
updated in this reland.
Original change's description:
> webnn: rename roundingType to outputShapeRounding for pool2d ops
>
> This CL renames MLPool2dOptions::roundingType to
> MLPool2dOptions::outputShapeRounding in test files and implementations
> according to Spec change [1].
>
> [1] webmachinelearning/webnn#770
>
> Bug: 498118207
> Change-Id: I815c7f7728071144835c0ada0747bc9de2999669
> Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139
> Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com>
> Reviewed-by: Reilly Grant <reillyg@chromium.org>
> Reviewed-by: Alex Gough <ajgo@chromium.org>
> Auto-Submit: Dai, Feng <feng.dai@intel.com>
> Commit-Queue: Dai, Feng <feng.dai@intel.com>
> Cr-Commit-Position: refs/heads/main@{#1618021}
Bug: 498118207
Change-Id: I4df2860081223af43493a0447ca5e69e104950df
Cq-Include-Trybots: luci.chromium.try:win11-blink-rel, win11-arm64-blink-rel, mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7882018
Reviewed-by: Joe Mason <joenotcharles@google.com>
Reviewed-by: Reilly Grant <reillyg@chromium.org>
Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com>
Commit-Queue: Dai, Feng <feng.dai@intel.com>
Reviewed-by: Elias Klim <elklm@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1639919}
…ops"
This is a reland of commit e5811467122a07253805711cf7331c2de1741f1d.
The original CL was reverted because two newly-added baseline files
under platform/win11-arm64/virtual/webnn-service-on-cpu/... still
referenced the old "roundingType" test names, which no longer matched
the renamed WPT cases ("outputShapeRounding"). Those baselines are
updated in this reland.
Original change's description:
> webnn: rename roundingType to outputShapeRounding for pool2d ops
>
> This CL renames MLPool2dOptions::roundingType to
> MLPool2dOptions::outputShapeRounding in test files and implementations
> according to Spec change [1].
>
> [1] webmachinelearning/webnn#770
>
> Bug: 498118207
> Change-Id: I815c7f7728071144835c0ada0747bc9de2999669
> Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139
> Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com>
> Reviewed-by: Reilly Grant <reillyg@chromium.org>
> Reviewed-by: Alex Gough <ajgo@chromium.org>
> Auto-Submit: Dai, Feng <feng.dai@intel.com>
> Commit-Queue: Dai, Feng <feng.dai@intel.com>
> Cr-Commit-Position: refs/heads/main@{#1618021}
Bug: 498118207
Change-Id: I4df2860081223af43493a0447ca5e69e104950df
Cq-Include-Trybots: luci.chromium.try:win11-blink-rel, win11-arm64-blink-rel, mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7882018
Reviewed-by: Joe Mason <joenotcharles@google.com>
Reviewed-by: Reilly Grant <reillyg@chromium.org>
Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com>
Commit-Queue: Dai, Feng <feng.dai@intel.com>
Reviewed-by: Elias Klim <elklm@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1639919}
…tputShapeRounding for pool2d ops", a=testonly
Automatic update from web-platform-tests
Reland "webnn: rename roundingType to outputShapeRounding for pool2d ops"
This is a reland of commit e5811467122a07253805711cf7331c2de1741f1d.
The original CL was reverted because two newly-added baseline files
under platform/win11-arm64/virtual/webnn-service-on-cpu/... still
referenced the old "roundingType" test names, which no longer matched
the renamed WPT cases ("outputShapeRounding"). Those baselines are
updated in this reland.
Original change's description:
> webnn: rename roundingType to outputShapeRounding for pool2d ops
>
> This CL renames MLPool2dOptions::roundingType to
> MLPool2dOptions::outputShapeRounding in test files and implementations
> according to Spec change [1].
>
> [1] webmachinelearning/webnn#770
>
> Bug: 498118207
> Change-Id: I815c7f7728071144835c0ada0747bc9de2999669
> Cq-Include-Trybots: luci.chromium.try:mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7717139
> Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com>
> Reviewed-by: Reilly Grant <reillyg@chromium.org>
> Reviewed-by: Alex Gough <ajgo@chromium.org>
> Auto-Submit: Dai, Feng <feng.dai@intel.com>
> Commit-Queue: Dai, Feng <feng.dai@intel.com>
> Cr-Commit-Position: refs/heads/main@{#1618021}
Bug: 498118207
Change-Id: I4df2860081223af43493a0447ca5e69e104950df
Cq-Include-Trybots: luci.chromium.try:win11-blink-rel, win11-arm64-blink-rel, mac14.arm64-blink-rel, mac15.arm64-blink-rel, mac15-blink-rel, linux-blink-rel
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7882018
Reviewed-by: Joe Mason <joenotcharles@google.com>
Reviewed-by: Reilly Grant <reillyg@chromium.org>
Reviewed-by: Hu, Ningxin <ningxin.hu@intel.com>
Commit-Queue: Dai, Feng <feng.dai@intel.com>
Reviewed-by: Elias Klim <elklm@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1639919}
--
wpt-commits: 58938037e8fd81f7a51b89985141c39ccf6922b1
wpt-pr: 60329
Fixes #324
Rather than having two output shape parameters, an explicit output size and an output rounding mode, be more explicit in WebNN such that the caller passes the explicit output shape, resolving any higher-level policy beforehand (like with
convTranspose2d):dictionary MLPool2dOptions : MLOperatorOptions { sequence<[EnforceRange] unsigned long> windowDimensions; sequence<[EnforceRange] unsigned long> padding; sequence<[EnforceRange] unsigned long> strides; sequence<[EnforceRange] unsigned long> dilations; MLInputOperandLayout layout = "nchw"; - MLRoundingType roundingType = "floor"; sequence<[EnforceRange] unsigned long> outputSizes; };Additional changes:
spec:infra; type:dfn; text:stringdue to new build failures unrelated to my change (thanks Dominique).Preview | Diff