code: def __init__(
      self,
      d_model,
      n_head,
      d_qkv,
      d_ff,
      ff_dropout,
      residual_dropout,
      attention_dropout,
      activation=PartitionedReLU(),
  ):
      super().__init__()
      self.self_attn = PartitionedMultiHeadAttention(
          d_model, n_head, d_qkv, attention_dropout=attention_dropout
      )
      self.linear1 = PartitionedLinear(d_model, d_ff)
      self.ff_dropout = FeatureDropout(ff_dropout)
      self.linear2 = PartitionedLinear(d_ff, d_model)
  
      self.norm_attn = nn.LayerNorm(d_model)
      self.norm_ff = nn.LayerNorm(d_model)
      self.residual_dropout_attn = FeatureDropout(residual_dropout)
      self.residual_dropout_ff = FeatureDropout(residual_dropout)
  
      self.activation = activation
  
imports: import copy
  import math
  import torch
  import torch.nn
  import torch.nn.functional
  from stanza.models.constituency.positional_encoding import ConcatSinusoidalEncoding
label_desc: Use image node_id 1 to create a new PartitionedTransformerEncoderLayer object from inherited base classes: nn with example: obj = PartitionedTransformerEncoderLayer(d_model, n_head, d_qkv, d_ff, ff_dropout, residual_dropout, attention_dropout, activation)