code: def __init__(
      self,
      hidden_size,
      intermediate_size,
      num_attention_heads,
      attention_probs_dropout_prob,
      fc_dropout_prob,
      act_fn="ReLU",
      output_attentions=False,
  ):
      super(BertLayer, self).__init__()
      self.attention = BertAttention(
          hidden_size,
          num_attention_heads,
          attention_probs_dropout_prob,
          output_attentions,
      )
      self.feed_forward = BertFeedForward(
          hidden_size,
          intermediate_size,
          num_attention_heads,
          attention_probs_dropout_prob,
          fc_dropout_prob,
          act_fn,
          output_attentions,
      )
  
imports: import paddle
  import paddle.nn
  import paddle.nn.functional
  from paddle.nn import ReLU, Swish, GELU
  import math
  from ppdet.core.workspace import register
  from ..shape_spec import ShapeSpec
label_desc: Use image node_id 1 to create a new BertLayer object from inherited base classes: nn with example: obj = BertLayer(hidden_size, intermediate_size, num_attention_heads, attention_probs_dropout_prob, fc_dropout_prob, act_fn, output_attentions)