From 02fdf24115219148a1c97bc8cb2f8c58b2d41fd7 Mon Sep 17 00:00:00 2001 From: tensor-tang Date: Mon, 23 Oct 2017 20:22:58 +0800 Subject: [PATCH] enable copyFrom of MKLDNNMatrix --- paddle/math/MKLDNNMatrix.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/paddle/math/MKLDNNMatrix.h b/paddle/math/MKLDNNMatrix.h index fe755d096da..2b62d4e11ac 100644 --- a/paddle/math/MKLDNNMatrix.h +++ b/paddle/math/MKLDNNMatrix.h @@ -91,6 +91,11 @@ public: const MKLDNNMatrixPtr& dst, bool checkData = true); + void copyFrom(const Matrix& src) { + // TODO(TJ): reorder data if this format is not nchw or x + m_->copyFrom(src); + } + public: /** * Reorder this MKLDNNMatrix from other format. -- GitLab