class_docstr: Gated Propogator for GGNN
  Using LSTM gating mechanism
class_docstr_tok: ["Gated","Propogator","for","GGNN","Using","LSTM","gating","mechanism"]
code: def forward(self, state_in, state_out, state_cur, edges, nodes):
      edges_in = edges[:, :, : nodes * self.n_edge_types]
      edges_out = edges[:, :, nodes * self.n_edge_types :]
  
      a_in = torch.bmm(edges_in, state_in)
      a_out = torch.bmm(edges_out, state_out)
      a = torch.cat((a_in, a_out, state_cur), 2)
  
      r = self.reset_gate(a)
      z = self.update_gate(a)
      joined_input = torch.cat((a_in, a_out, r * state_cur), 2)
      h_hat = self.tansform(joined_input)
  
      prop_out = (1 - z) * state_cur + z * h_hat
  
      return prop_out
  
imports: import numpy
  import torch
  import torch.nn
  import torch.nn.functional
  from onmt.encoders.encoder import EncoderBase
label_desc: Use image node_id 2 for calling the GGNNPropogator obj's underlying member method code with example usage: obj.forward(state_in, state_out, state_cur, edges, nodes) and returns: prop_out