class_docstr: Multi-headed attention from 'Attention Is All You Need' paper
class_docstr_tok: ["Multi-headed","attention","from","'Attention","Is","All","You","Need","'","paper"]
code: def _shape(self, tensor: torch.Tensor, seq_len: int, bsz: int):
      return (
          tensor.view(bsz, seq_len, self.num_heads, self.head_dim)
          .transpose(1, 2)
          .contiguous()
      )
  
imports: import math
  from typing import Optional, Tuple
  import pdb
  import torch
  from torch import nn
  import torch.utils.checkpoint
  import torch.nn.functional
  from transformers.models.llama.modeling_llama import LlamaAttention, rotate_half, apply_rotary_pos_emb, LlamaRotaryEmbedding, apply_rotary_pos_emb, LlamaForCausalLM
  import types
  from transformers.configuration_utils import PretrainedConfig
label_desc: Use image node_id 3 for calling the H2OLlamaAttention obj's underlying member method code with example usage: obj._shape(tensor, seq_len, bsz) and returns: tensor