Skip to content

Commit

Permalink
fix for gaussian random
Browse files Browse the repository at this point in the history
  • Loading branch information
jakpiase committed Apr 8, 2022
1 parent 330582e commit d4d3467
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion paddle/fluid/operators/mkldnn/gaussian_random_mkldnn_op.cc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ limitations under the License. */

#include "paddle/fluid/framework/generator.h"
#include "paddle/fluid/operators/fill_constant_op.h"
#include "paddle/fluid/platform/mkldnn_helper.h"

namespace paddle {
namespace operators {
Expand All @@ -42,7 +43,7 @@ class GaussianMKLDNNKernel : public paddle::framework::OpKernel<T> {
}

tensor->set_layout(DataLayout::kMKLDNN);
tensor->set_format(dnnl::memory::format_tag::oihw);
tensor->set_format(platform::GetPlainMKLDNNFormat(tensor->dims().size()));
}
};
} // namespace operators
Expand Down

1 comment on commit d4d3467

@paddle-bot-old
Copy link

Choose a reason for hiding this comment

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

Congratulation! Your pull request passed all required CI. You could ask reviewer(s) to approve and merge. 🎉

Please sign in to comment.