Commit fc75c8a4 authored by Adam Rogowiec's avatar Adam Rogowiec Committed by arogowie-intel

Store member shared_ptrs as object.

parent 61aed897
...@@ -230,7 +230,7 @@ namespace ngraph ...@@ -230,7 +230,7 @@ namespace ngraph
class LSTMForward class LSTMForward
{ {
public: public:
explicit LSTMForward(std::shared_ptr<ngraph::Node> X, explicit LSTMForward(const std::shared_ptr<ngraph::Node>& X,
const std::shared_ptr<ngraph::Node>& W, const std::shared_ptr<ngraph::Node>& W,
const std::shared_ptr<ngraph::Node>& R, const std::shared_ptr<ngraph::Node>& R,
const std::shared_ptr<ngraph::Node>& B, const std::shared_ptr<ngraph::Node>& B,
...@@ -417,13 +417,13 @@ namespace ngraph ...@@ -417,13 +417,13 @@ namespace ngraph
} }
std::shared_ptr<ngraph::Node> m_X; std::shared_ptr<ngraph::Node> m_X;
const std::shared_ptr<ngraph::Node>& m_W; std::shared_ptr<ngraph::Node> m_W;
const std::shared_ptr<ngraph::Node>& m_R; std::shared_ptr<ngraph::Node> m_R;
const std::shared_ptr<ngraph::Node>& m_B; std::shared_ptr<ngraph::Node> m_B;
const std::shared_ptr<ngraph::Node>& m_P; std::shared_ptr<ngraph::Node> m_P;
const std::shared_ptr<ngraph::Node>& m_initial_h; std::shared_ptr<ngraph::Node> m_initial_h;
const std::shared_ptr<ngraph::Node>& m_initial_c; std::shared_ptr<ngraph::Node> m_initial_c;
const std::shared_ptr<ngraph::Node>& m_seq_lengths; std::shared_ptr<ngraph::Node> m_seq_lengths;
const LSTMAttributes& m_attributes; const LSTMAttributes& m_attributes;
}; };
......
...@@ -146,23 +146,23 @@ namespace ngraph ...@@ -146,23 +146,23 @@ namespace ngraph
/// ///
/// \brief The input data tensor. Shape: [batch_size, input_size]. /// \brief The input data tensor. Shape: [batch_size, input_size].
/// ///
const std::shared_ptr<Node>& m_X; std::shared_ptr<Node> m_X;
/// ///
/// \brief The weight tensor. Shape: [4*hidden_size, input_size]. /// \brief The weight tensor. Shape: [4*hidden_size, input_size].
/// ///
const std::shared_ptr<Node>& m_W; std::shared_ptr<Node> m_W;
/// ///
/// \brief The recurrence weight tensor. Shape: [4*hidden_size, hidden_size]. /// \brief The recurrence weight tensor. Shape: [4*hidden_size, hidden_size].
/// ///
const std::shared_ptr<Node>& m_R; std::shared_ptr<Node> m_R;
/// ///
/// \brief The hidden state tensor at current time step. Shape: [batch_size, hidden_size]. /// \brief The hidden state tensor at current time step. Shape: [batch_size, hidden_size].
/// ///
const std::shared_ptr<Node>& m_H_t; std::shared_ptr<Node> m_H_t;
/// ///
/// \brief The cell state tensor at current time step. Shape: [batch_size, hidden_size]. /// \brief The cell state tensor at current time step. Shape: [batch_size, hidden_size].
/// ///
const std::shared_ptr<Node>& m_C_t; std::shared_ptr<Node> m_C_t;
/// ///
/// \brief The weight tensor for peepholes with shape: [3*hidde_size] - 3 equals to /// \brief The weight tensor for peepholes with shape: [3*hidde_size] - 3 equals to
/// only iof gates. /// only iof gates.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment