class_docstr: The quasi-dense roi embed head.
  
  Args:
      embed_channels (int): The input channel of embed features.
          Defaults to 256.
      softmax_temp (int): Softmax temperature. Defaults to -1.
      loss_track (dict): The loss function for tracking. Defaults to
          MultiPosCrossEntropyLoss.
      loss_track_aux (dict): The auxiliary loss function for tracking.
          Defaults to MarginL2Loss.
      init_cfg (:obj:`ConfigDict` or dict or list[:obj:`ConfigDict` or             dict]): Initialization config dict.
class_docstr_tok: ["The","quasi-dense","roi","embed","head",".","Args",":","embed_channels","(","int",")",":","The","input","channel","of","embed","features",".","Defaults","to","256.","softmax_temp","(","int",")",":","Softmax","temperature",".","Defaults","to","-1.","loss_track","(","dict",")",":","The","loss","function","for","tracking",".","Defaults","to","MultiPosCrossEntropyLoss",".","loss_track_aux","(","dict",")",":","The","auxiliary","loss","function","for","tracking",".","Defaults","to","MarginL2Loss",".","init_cfg","(",":","obj",":","`","ConfigDict","`","or","dict","or","list","[",":","obj",":","`","ConfigDict","`","or","dict","]",")",":","Initialization","config","dict","."]
docstr: Forward function.
  
  Args:
      x (Tensor): The input features from ROI head.
  
  Returns:
      Tensor: The embedding feature map.
docstr_tok: ["Forward","function",".","Args",":","x","(","Tensor",")",":","The","input","features","from","ROI","head",".","Returns",":","Tensor",":","The","embedding","feature","map","."]
code: def forward(self, x: Tensor) -> Tensor:
      """Forward function.
  
      Args:
          x (Tensor): The input features from ROI head.
  
      Returns:
          Tensor: The embedding feature map.
      """
  
      if self.num_convs > 0:
          for conv in self.convs:
              x = conv(x)
      x = x.flatten(1)
      if self.num_fcs > 0:
          for fc in self.fcs:
              x = self.relu(fc(x))
      x = self.fc_embed(x)
      return x
  
file_path: mmdetection/mmdet/models/tracking_heads/quasi_dense_embed_head.py
imports: from typing import List, Optional, Tuple
  import torch
  import torch.nn
  from mmcv.cnn import ConvModule
  from mmengine.model import BaseModule
  from torch import Tensor
  from torch.nn.modules.utils import _pair
  from mmdet.models.task_modules import SamplingResult
  from mmdet.registry import MODELS
  from ..task_modules.tracking import embed_similarity
label_desc: Use image node_id 3 for calling the QuasiDenseEmbedHead obj's underlying member method code with example usage: obj.forward(x) and returns: x