code: def __init__(
      self,
      node_feats,
      edge_feats,
      out_feats,
      n_heads=1,
      attn_drop=0.0,
      edge_drop=0.0,
      negative_slope=0.2,
      residual=True,
      activation=None,
      use_attn_dst=True,
      allow_zero_in_degree=True,
      use_symmetric_norm=False,
  ):
      super(GATConv, self).__init__()
      self._n_heads = n_heads
      self._in_src_feats, self._in_dst_feats = expand_as_pair(
          node_feats
      )
      self._out_feats = out_feats
      self._allow_zero_in_degree = allow_zero_in_degree
      self._use_symmetric_norm = use_symmetric_norm
  
      # feat fc
      self.src_fc = nn.Linear(
          self._in_src_feats, out_feats * n_heads, bias=False
      )
      if residual:
          self.dst_fc = nn.Linear(
              self._in_src_feats, out_feats * n_heads
          )
          self.bias = None
      else:
          self.dst_fc = None
          self.bias = nn.Parameter(out_feats * n_heads)
  
      # attn fc
      self.attn_src_fc = nn.Linear(
          self._in_src_feats, n_heads, bias=False
      )
      if use_attn_dst:
          self.attn_dst_fc = nn.Linear(
              self._in_src_feats, n_heads, bias=False
          )
      else:
          self.attn_dst_fc = None
      if edge_feats > 0:
          self.attn_edge_fc = nn.Linear(edge_feats, n_heads, bias=False)
      else:
          self.attn_edge_fc = None
  
      self.attn_drop = nn.Dropout(attn_drop)
      self.edge_drop = edge_drop
      self.leaky_relu = nn.LeakyReLU(negative_slope, inplace=True)
      self.activation = activation
  
      self.reset_parameters()
  
imports: import math
  from functools import partial
  import dgl.function
  import dgl.nn.pytorch
  import torch
  import torch.nn
  import torch.nn.functional
  from dgl import function
  from dgl._ffi.base import DGLError
  from dgl.base import ALL
  from dgl.nn.pytorch.utils import Identity
  from dgl.ops import edge_softmax
  from dgl.utils import expand_as_pair
  from torch.nn import init
  from torch.utils.checkpoint import checkpoint
label_desc: Use image node_id 1 to create a new GATConv object from inherited base classes: nn with example: obj = GATConv(node_feats, edge_feats, out_feats, n_heads, attn_drop, edge_drop, negative_slope, residual, activation, use_attn_dst, allow_zero_in_degree, use_symmetric_norm)