class_docstr: Localization distillation Head. (Short description)
  
  It utilizes the learned bbox distributions to transfer the localization
  dark knowledge from teacher to student. Original paper: `Localization
  Distillation for Object Detection. <https://arxiv.org/abs/2102.12252>`_
  
  Args:
      num_classes (int): Number of categories excluding the background
          category.
      in_channels (int): Number of channels in the input feature map.
      loss_ld (:obj:`ConfigDict` or dict): Config of Localization
          Distillation Loss (LD), T is the temperature for distillation.
class_docstr_tok: ["Localization","distillation","Head",".","(","Short","description",")","It","utilizes","the","learned","bbox","distributions","to","transfer","the","localization","dark","knowledge","from","teacher","to","student",".","Original","paper",":","`","Localization","Distillation","for","Object","Detection",".","<","https",":","\/\/arxiv.org\/abs\/2102.12252",">","`","_","Args",":","num_classes","(","int",")",":","Number","of","categories","excluding","the","background","category",".","in_channels","(","int",")",":","Number","of","channels","in","the","input","feature","map",".","loss_ld","(",":","obj",":","`","ConfigDict","`","or","dict",")",":","Config","of","Localization","Distillation","Loss","(","LD",")",",","T","is","the","temperature","for","distillation","."]
code: def __init__(
      self,
      num_classes: int,
      in_channels: int,
      loss_ld: ConfigType = dict(
          type="LocalizationDistillationLoss", loss_weight=0.25, T=10
      ),
      **kwargs,
  ) -> dict:
      super().__init__(
          num_classes=num_classes, in_channels=in_channels, **kwargs
      )
      self.loss_ld = MODELS.build(loss_ld)
  
file_path: mmdetection/mmdet/models/dense_heads/ld_head.py
imports: from typing import List, Tuple
  import torch
  from torch import Tensor
  from mmdet.registry import MODELS
  from mmdet.structures import SampleList
  from mmdet.structures.bbox import bbox_overlaps
  from mmdet.utils import ConfigType, InstanceList, OptInstanceList, reduce_mean
  from ..utils import multi_apply, unpack_gt_instances
  from .gfl_head import GFLHead
label_desc: Use image node_id 1 to create a new LDHead object from inherited base classes: GFLHead with example: obj = LDHead(num_classes, in_channels, loss_ld)