class_docstr: Early Fusion Module.
  
  Args:
      v_dim (int): Dimension of visual features.
      l_dim (int): Dimension of language features.
      embed_dim (int): The embedding dimension for the attention operation.
      num_heads (int): Number of attention heads.
      dropout (float): Dropout probability.
      drop_path (float): Drop path probability.
      use_checkpoint (bool): Whether to use PyTorch's checkpoint function.
class_docstr_tok: ["Early","Fusion","Module",".","Args",":","v_dim","(","int",")",":","Dimension","of","visual","features",".","l_dim","(","int",")",":","Dimension","of","language","features",".","embed_dim","(","int",")",":","The","embedding","dimension","for","the","attention","operation",".","num_heads","(","int",")",":","Number","of","attention","heads",".","dropout","(","float",")",":","Dropout","probability",".","drop_path","(","float",")",":","Drop","path","probability",".","use_checkpoint","(","bool",")",":","Whether","to","use","PyTorch","'s","checkpoint","function","."]
code: def __init__(
      self,
      v_dim: int = 256,
      l_dim: int = 768,
      embed_dim: int = 2048,
      num_heads: int = 8,
      dropout: float = 0.1,
      drop_path: float = 0.0,
      use_checkpoint: bool = False,
  ):
      super().__init__()
      self.use_checkpoint = use_checkpoint
      self.b_attn = BiAttentionBlock(
          v_dim=v_dim,
          l_dim=l_dim,
          embed_dim=embed_dim,
          num_heads=num_heads,
          dropout=dropout,
          drop_path=drop_path,
          init_values=1.0 / 6.0,
      )
  
imports: import math
  from typing import Dict, Optional, Tuple
  import torch
  import torch.nn
  import torch.nn.functional
  import torch.utils.checkpoint
  from mmcv.cnn.bricks import DropPath
  from torch import Tensor
label_desc: Use image node_id 1 to create a new VLFuse object from inherited base classes: nn with example: obj = VLFuse(v_dim, l_dim, embed_dim, num_heads, dropout, drop_path, use_checkpoint)