docstr: @nodes: tensor of shape (batch_size, num_side_info)
docstr_tok: ["@","nodes",":","tensor","of","shape","(","batch_size",",","num_side_info",")"]
code: def query_node_embed(self, nodes):
      """
      @nodes: tensor of shape (batch_size, num_side_info)
      """
      batch_size = nodes.shape[0]
      # query side info weights, (batch_size, 4)
      side_info_weights = th.exp(self.side_info_weights(nodes[:, 0]))
      # merge all embeddings
      side_info_weighted_embeds_sum = []
      side_info_weights_sum = []
      for i in range(4):
          # weights for i-th side info, (batch_size, ) -> (batch_size, 1)
          i_th_side_info_weights = side_info_weights[:, i].view(
              (batch_size, 1)
          )
          # batch of i-th side info embedding * its weight, (batch_size, dim)
          side_info_weighted_embeds_sum.append(
              i_th_side_info_weights * self.embeds[i](nodes[:, i])
          )
          side_info_weights_sum.append(i_th_side_info_weights)
      # stack: (batch_size, 4, dim), sum: (batch_size, dim)
      side_info_weighted_embeds_sum = th.sum(
          th.stack(side_info_weighted_embeds_sum, axis=1), axis=1
      )
      # stack: (batch_size, 4), sum: (batch_size, )
      side_info_weights_sum = th.sum(
          th.stack(side_info_weights_sum, axis=1), axis=1
      )
      # (batch_size, dim)
      H = side_info_weighted_embeds_sum / side_info_weights_sum
  
      return H
  
imports: import torch
label_desc: Use image node_id 3 for calling the EGES obj's underlying member method code with example usage: obj.query_node_embed(nodes) and returns: H