From 1d9a4d2e500416c2ba408174884a1d9102e45dae Mon Sep 17 00:00:00 2001 From: fengjiayi Date: Wed, 6 Sep 2017 22:12:02 -0700 Subject: [PATCH] Move some comments to .h file --- paddle/framework/ddim.cc | 2 -- paddle/framework/ddim.h | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/paddle/framework/ddim.cc b/paddle/framework/ddim.cc index 58e20625ce7..fc3d508553c 100644 --- a/paddle/framework/ddim.cc +++ b/paddle/framework/ddim.cc @@ -284,8 +284,6 @@ DDim::DDim(std::initializer_list init_list) { *this = make_ddim(init_list); } -// Reshape a tensor to a matrix. The matrix's first dimension(column length) -// will be the product of tensor's first `num_col_dims` dimensions DDim flatten_to_2d(const DDim& src, int num_col_dims) { int rank = src.size(); return make_ddim({product(slice_ddim(src, 0, num_col_dims)), diff --git a/paddle/framework/ddim.h b/paddle/framework/ddim.h index 1e7ca46bd98..48e14d16e3e 100644 --- a/paddle/framework/ddim.h +++ b/paddle/framework/ddim.h @@ -115,6 +115,8 @@ int arity(const DDim& ddim); std::ostream& operator<<(std::ostream&, const DDim&); +// Reshape a tensor to a matrix. The matrix's first dimension(column length) +// will be the product of tensor's first `num_col_dims` dimensions DDim flatten_to_2d(const DDim& src, int num_col_dims); DDim flatten_to_1d(const DDim& src); -- GitLab