From a9be969cf94b16105831831ac4ff85139eaef849 Mon Sep 17 00:00:00 2001 From: Jiabin Yang Date: Fri, 31 Aug 2018 02:20:59 +0800 Subject: [PATCH] Update attention_lstm_fuse_pass.cc --- paddle/fluid/framework/ir/attention_lstm_fuse_pass.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/paddle/fluid/framework/ir/attention_lstm_fuse_pass.cc b/paddle/fluid/framework/ir/attention_lstm_fuse_pass.cc index c82bbda57e..5cb37ea925 100644 --- a/paddle/fluid/framework/ir/attention_lstm_fuse_pass.cc +++ b/paddle/fluid/framework/ir/attention_lstm_fuse_pass.cc @@ -217,10 +217,10 @@ void PrepareLSTMWeight(const LoDTensor& W_forget_w0, float* out_data = out->mutable_data(platform::CPUPlace()); std::array tensors( {{W_forget_w0.data(), W_input_w0.data(), - W_output_w0.data(), W_cell_w0.data()}}); + W_output_w0.data(), W_cell_w0.data()}}); std::array tensors1( {{W_forget_w1.data(), W_input_w1.data(), - W_output_w1.data(), W_cell_w1.data()}}); + W_output_w1.data(), W_cell_w1.data()}}); for (int row = 0; row < D; row++) { for (int col = 0; col < 4; col++) { @@ -244,7 +244,7 @@ void PrepareLSTMBias(const LoDTensor& B_forget, const LoDTensor& B_input, LoDTensor* out) { std::array tensors( {{B_forget.data(), B_input.data(), B_output.data(), - B_cell.data()}}); + B_cell.data()}}); PADDLE_ENFORCE_EQ(B_forget.dims().size(), 1); int D = B_forget.dims()[0]; -- GitLab