code: def get_gpt_layer_local_spec(
      num_experts: int = None, moe_grouped_gemm: bool = False
  ) -> ModuleSpec:
      mlp = _get_mlp_module_spec(
          use_te=False,
          num_experts=num_experts,
          moe_grouped_gemm=moe_grouped_gemm,
      )
      return ModuleSpec(
          module=TransformerLayer,
          submodules=TransformerLayerSubmodules(
              input_layernorm=FusedLayerNorm,
              self_attention=ModuleSpec(
                  module=SelfAttention,
                  params={"attn_mask_type": AttnMaskType.causal},
                  submodules=SelfAttentionSubmodules(
                      linear_qkv=ColumnParallelLinear,
                      core_attention=DotProductAttention,
                      linear_proj=RowParallelLinear,
                  ),
              ),
              self_attn_bda=get_bias_dropout_add,
              pre_mlp_layernorm=FusedLayerNorm,
              mlp=mlp,
              mlp_bda=get_bias_dropout_add,
          ),
      )
  
file_path: megatron-lm/megatron/core/models/gpt/gpt_layer_specs.py
imports: from megatron.core.fusions.fused_bias_dropout import get_bias_dropout_add
  from megatron.core.fusions.fused_layer_norm import FusedLayerNorm
  from megatron.core.tensor_parallel.layers import ColumnParallelLinear, RowParallelLinear
  from megatron.core.transformer.attention import SelfAttention, SelfAttentionSubmodules
  from megatron.core.transformer.custom_layers.transformer_engine import TEDotProductAttention, TELayerNormColumnParallelLinear, TENorm, TERowParallelLinear
  from megatron.core.transformer.dot_product_attention import DotProductAttention
  from megatron.core.transformer.enums import AttnMaskType
  from megatron.core.transformer.identity_op import IdentityOp
  from megatron.core.transformer.mlp import MLP, MLPSubmodules
  from megatron.core.transformer.moe.grouped_mlp import GroupedMLP
  from megatron.core.transformer.moe.switch_mlp import SwitchMLP
  from megatron.core.transformer.spec_utils import ModuleSpec
  from megatron.core.transformer.transformer_layer import TransformerLayer, TransformerLayerSubmodules
label_desc: Use image node_id 2 for calling a global function with example usage: get_gpt_layer_local_spec(num_experts, moe_grouped_gemm) and returns: ModuleSpec