Skip to content

Conversation

@XiaobingSuper
Copy link
Collaborator

@XiaobingSuper XiaobingSuper commented May 16, 2019

mkldnn backward ops list:

@pytorchbot pytorchbot added module: autograd Related to torch.autograd, and the autograd engine in general module: internals Related to internal abstractions in c10 and ATen module: mkldnn Related to Intel IDEEP or oneDNN (a.k.a. mkldnn) integration module: operators labels May 16, 2019
@li-roy li-roy added the triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module label May 16, 2019
facebook-github-bot pushed a commit that referenced this pull request Jun 13, 2019
Summary:
### mkldnn backward ops list:
 - [ ] \(#20567) Add aten mkldnn conv2d backward operator 💛
 - [ ] \(#20570) Add aten mkldnn backward ops: relu, linear and reshape 💛
 - [ ] \(#20571) Add aten mkldnn backward ops: max_pool2d, avg_pool2d and adaptive_avg_poo2d 💛
 - [ ] \(#20572) Add aten mkldnn batchnorm backward operator 💛
 - [ ] \(#20573) Add aten mkldnn zero_ operator:yellow_heart:
 - [ ] \(#20575) Add mkldnn mul operator 💛
Pull Request resolved: #20575

Differential Revision: D15799529

Pulled By: bddppq

fbshipit-source-id: 4887d8ef1a0e316ad9db199b657d9481fc13e486
zdevito pushed a commit to zdevito/ATen that referenced this pull request Jun 13, 2019
Summary:
### mkldnn backward ops list:
 - [ ] \(pytorch/pytorch#20567) Add aten mkldnn conv2d backward operator 💛
 - [ ] \(pytorch/pytorch#20570) Add aten mkldnn backward ops: relu, linear and reshape 💛
 - [ ] \(pytorch/pytorch#20571) Add aten mkldnn backward ops: max_pool2d, avg_pool2d and adaptive_avg_poo2d 💛
 - [ ] \(pytorch/pytorch#20572) Add aten mkldnn batchnorm backward operator 💛
 - [ ] \(pytorch/pytorch#20573) Add aten mkldnn zero_ operator:yellow_heart:
 - [ ] \(pytorch/pytorch#20575) Add mkldnn mul operator 💛
Pull Request resolved: pytorch/pytorch#20575

Differential Revision: D15799529

Pulled By: bddppq

fbshipit-source-id: 4887d8ef1a0e316ad9db199b657d9481fc13e486
@gottbrath gottbrath requested a review from bddppq June 13, 2019 17:09
facebook-github-bot pushed a commit that referenced this pull request Jun 14, 2019
Summary:
### mkldnn backward ops list:
 - [ ] \(#20567) Add aten mkldnn conv2d backward operator 💛
 - [ ] \(#20570) Add aten mkldnn backward ops: relu, linear and reshape 💛
 - [ ] \(#20571) Add aten mkldnn backward ops: max_pool2d, avg_pool2d and adaptive_avg_poo2d 💛
 - [ ] \(#20572) Add aten mkldnn batchnorm backward operator 💛
 - [ ] \(#20573) Add aten mkldnn zero_ operator:yellow_heart:
 - [ ] \(#20575) Add mkldnn mul operator 💚
Pull Request resolved: #20573

Differential Revision: D15820477

Pulled By: bddppq

fbshipit-source-id: 35d95f5b4e013c8db1911f52148550a2e40a2e68
zdevito pushed a commit to zdevito/ATen that referenced this pull request Jun 14, 2019
Summary:
### mkldnn backward ops list:
 - [ ] \(pytorch/pytorch#20567) Add aten mkldnn conv2d backward operator 💛
 - [ ] \(pytorch/pytorch#20570) Add aten mkldnn backward ops: relu, linear and reshape 💛
 - [ ] \(pytorch/pytorch#20571) Add aten mkldnn backward ops: max_pool2d, avg_pool2d and adaptive_avg_poo2d 💛
 - [ ] \(pytorch/pytorch#20572) Add aten mkldnn batchnorm backward operator 💛
 - [ ] \(pytorch/pytorch#20573) Add aten mkldnn zero_ operator:yellow_heart:
 - [ ] \(pytorch/pytorch#20575) Add mkldnn mul operator 💚
Pull Request resolved: pytorch/pytorch#20573

Differential Revision: D15820477

Pulled By: bddppq

fbshipit-source-id: 35d95f5b4e013c8db1911f52148550a2e40a2e68
@gottbrath gottbrath requested review from dzhulgakov and gchanan June 25, 2019 16:22
# NB: `output` instead of `self` saves memory. It avoids saving a copy of self.
- name: relu_(Tensor self)
self: threshold_backward(grad, result, 0)
self: relu_backward(grad, result)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I wonder whether it'd have been easier to just implement threshold_backward directly for mkldnn and error out if threshold is non zero. That way you'd need to change less of existing code.

- name: mkldnn_linear(Tensor input, Tensor weight, Tensor bias)
input, weight, bias: mkldnn_linear_backward(input, grad, weight, grad_input_mask)

- name: mkldnn_reshape(Tensor self, IntArrayRef shape)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm surprised it does what you want, the method name in native_functions.yaml starts with underscore: _mkldnn_reshape

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

solve it.

@XiaobingSuper
Copy link
Collaborator Author

We should first expose aten::linear to using mkldnn linear training, So this PR depend on #20039 , so please merge #20039 first.

@XiaobingSuper
Copy link
Collaborator Author

@VitalyFedyunin

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

Labels

module: autograd Related to torch.autograd, and the autograd engine in general module: internals Related to internal abstractions in c10 and ATen module: mkldnn Related to Intel IDEEP or oneDNN (a.k.a. mkldnn) integration open source triaged This issue has been looked at a team member, and triaged and prioritized into an appropriate module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants