Skip to content
This repository was archived by the owner on Nov 17, 2023. It is now read-only.

Add oneDNN support for reduce operators#20669

Merged
bgawrych merged 9 commits intoapache:masterfrom
bgawrych:onednn_reduction
Nov 26, 2021
Merged

Add oneDNN support for reduce operators#20669
bgawrych merged 9 commits intoapache:masterfrom
bgawrych:onednn_reduction

Conversation

@bgawrych
Copy link
Contributor

Description

Add oneDNN support for reduction operators: sum and mean, for both nd and np interfaces

@mxnet-bot
Copy link

Hey @bgawrych , Thanks for submitting the PR
All tests are already queued to run once. If tests fail, you can trigger one or more tests again with the following commands:

  • To trigger all jobs: @mxnet-bot run ci [all]
  • To trigger specific jobs: @mxnet-bot run ci [job1, job2]

CI supported jobs: [sanity, miscellaneous, website, centos-cpu, clang, centos-gpu, windows-gpu, windows-cpu, unix-cpu, unix-gpu, edge]


Note:
Only following 3 categories can trigger CI :PR Author, MXNet Committer, Jenkins Admin.
All CI tests must pass before the PR can be merged.

@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress and removed pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress labels Oct 14, 2021
@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress and removed pr-work-in-progress PR is still work in progress pr-awaiting-testing PR is reviewed and waiting CI build and test labels Oct 19, 2021
@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress and removed pr-work-in-progress PR is still work in progress pr-awaiting-testing PR is reviewed and waiting CI build and test labels Oct 26, 2021
@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress and removed pr-work-in-progress PR is still work in progress pr-awaiting-testing PR is reviewed and waiting CI build and test labels Nov 10, 2021
@bgawrych
Copy link
Contributor Author

@mxnet-bot run ci [website, unix-gpu, unix-cpu, miscellaneous]

@mxnet-bot
Copy link

Jenkins CI successfully triggered : [unix-gpu, unix-cpu, website, miscellaneous]

@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test and removed pr-work-in-progress PR is still work in progress pr-awaiting-testing PR is reviewed and waiting CI build and test labels Nov 12, 2021
@bgawrych
Copy link
Contributor Author

@mxnet-bot run ci [website, unix-gpu]

@mxnet-bot
Copy link

Jenkins CI successfully triggered : [unix-gpu, website]

Copy link
Contributor

@bartekkuncer bartekkuncer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good. Only some cosmetic changes.

@bgawrych
Copy link
Contributor Author

@mxnet-bot run ci [miscellaneous, windows-gpu]

@mxnet-bot
Copy link

Jenkins CI successfully triggered : [miscellaneous, windows-gpu]

@bgawrych
Copy link
Contributor Author

Perf results on CLX8280 (28 cores):

image

Script:

import mxnet
import mxnet.gluon.nn as nn
import mxnet.numpy as np
import time

dims = [128, 512, 1024, 4096]
print("shape;axis;time;mean")
for ndim in range (2):
   for dim1 in dims:
     for dim2 in dims:
        shape = (dim1, dim2) if ndim == 0 else (32, dim1, dim2)
        a = np.random.uniform(-1.0, 1.0, shape).astype(np.float32)
        for axis in range(2 + ndim):
            tic = time.time()
            for i in range(100):
                out = np.mean(a, axis=axis)
                out.wait_to_read()
            toc = time.time()
            print(f"{shape};{axis};{toc-tic}")

@bgawrych
Copy link
Contributor Author

Merging, @szha if there is any procedure of merging own commits let me know

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

pr-awaiting-review PR is waiting for code review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants