class_docstr: Transformer encoder model.
      
class_docstr_tok: ["Transformer","encoder","model","."]
code: def _build_cross_attn_layer(self):
      return ParallelTransformer(
          config=self.config,
          layer_type=LayerType.decoder,
          init_method=self.init_method,
          output_layer_init_method=self.output_layer_init_method,
          num_layers=1,
          hidden_size=self.hidden_size,
          num_attention_heads=self.num_attention_heads,
          apply_query_key_layer_scaling=self.apply_query_key_layer_scaling,
          kv_channels=self.kv_channels,
          ffn_hidden_size=self.ffn_hidden_size,
          self_attn_mask_type=self.model_attn_mask_type,
          pre_process=self.pre_process,
          post_process=False,  # This is to avoid the final layernorm and transpose.
          precision=self.precision,
          fp32_residual_connection=self.fp32_residual_connection,
          activations_checkpoint_method=self.activations_checkpoint_method,
          activations_checkpoint_num_layers=self.activations_checkpoint_num_layers,
          activations_checkpoint_granularity=self.activations_checkpoint_granularity,
          layernorm_epsilon=self.layernorm_epsilon,
          hidden_dropout=self.hidden_dropout,
          attention_dropout=self.attention_dropout,
          ffn_dropout=self.ffn_dropout,
          bias_activation_fusion=self.bias_activation_fusion,
          bias_dropout_add_fusion=self.bias_dropout_add_fusion,
          masked_softmax_fusion=self.masked_softmax_fusion,
          persist_layer_norm=self.persist_layer_norm,
          openai_gelu=self.openai_gelu,
          onnx_safe=self.onnx_safe,
          activation=self.activation,
          bias=self.bias,
          normalization=self.normalization,
          model_type=self.parent_model_type,
          transformer_block_type=self.transformer_block_type,
          headscale=self.headscale,
          normalize_attention_scores=self.normalize_attention_scores,
          megatron_legacy=self.megatron_legacy,
      )
  
file_path: NeMo/nemo/collections/nlp/modules/common/megatron/megatron_perceiver_encoders.py
imports: import torch
  from nemo.collections.nlp.modules.common.megatron.fused_layer_norm import get_layer_norm
  from nemo.collections.nlp.modules.common.megatron.layer_type import LayerType
  from nemo.collections.nlp.modules.common.megatron.module import MegatronModule
  from nemo.collections.nlp.modules.common.megatron.transformer import ParallelTransformer
  from nemo.collections.nlp.modules.common.megatron.utils import ApexGuardDefaults, attn_mask_postprocess, build_attention_mask_3d
label_desc: Use image node_id 2 for calling the MegatronPerceiverEncoderModule obj's underlying member method code with example usage: obj._build_cross_attn_layer() and returns: ParallelTransformer