class_docstr: A warpper for torch.nn.MultiheadAttention.
  
  This module implements MultiheadAttention with residual connection,
  and positional encoding used in DETR is also passed as input.
  
  Args:
      embed_dims (int): The embedding dimension.
      num_heads (int): Parallel attention heads. Same as
          `nn.MultiheadAttention`.
      dropout (float): A Dropout layer on attn_output_weights. Default 0.0.
class_docstr_tok: ["A","warpper","for","torch.nn.MultiheadAttention",".","This","module","implements","MultiheadAttention","with","residual","connection",",","and","positional","encoding","used","in","DETR","is","also","passed","as","input",".","Args",":","embed_dims","(","int",")",":","The","embedding","dimension",".","num_heads","(","int",")",":","Parallel","attention","heads",".","Same","as","`","nn.MultiheadAttention","`",".","dropout","(","float",")",":","A","Dropout","layer","on","attn_output_weights",".","Default","0.0","."]
docstr: str: a string that describes the module
docstr_tok: ["str",":","a","string","that","describes","the","module"]
code: def __repr__(self):
      """str: a string that describes the module"""
      repr_str = self.__class__.__name__
      repr_str += f"(embed_dims={self.embed_dims}, "
      repr_str += f"num_heads={self.num_heads}, "
      repr_str += f"dropout={self.dropout})"
      return repr_str
  
imports: import torch
  import torch.nn
  from mmcv.cnn import Linear, build_activation_layer, build_norm_layer, xavier_init
  from .builder import TRANSFORMER
label_desc: Use image node_id 3 for calling the MultiheadAttention obj's underlying member method code with example usage: obj.__repr__() and returns: repr_str