code: def __init__(self, phase: str, pretrained: bool) -> None:
      super().__init__()
      self.phase = phase
      self.num_classes = 2
  
      self.model0 = Conv_head(3, 16, 16)
      self.model1 = Conv4layerBlock(16, 64)
      self.model2 = Conv4layerBlock(64, 64)
      self.model3 = Conv4layerBlock(64, 64)
      self.model4 = Conv4layerBlock(64, 64)
      self.model5 = Conv4layerBlock(64, 64)
      self.model6 = Conv4layerBlock(64, 64)
  
      self.head = nn.Sequential(
          Conv4layerBlock(64, 3 * (14 + 2 + 1), False),
          Conv4layerBlock(64, 2 * (14 + 2 + 1), False),
          Conv4layerBlock(64, 2 * (14 + 2 + 1), False),
          Conv4layerBlock(64, 3 * (14 + 2 + 1), False),
      )
  
      if self.phase == "train":
          for m in self.modules():
              if isinstance(m, nn.Conv2d):
                  if m.bias is not None:
                      nn.init.xavier_normal_(m.weight.data)
                      m.bias.data.fill_(0.02)
                  else:
                      m.weight.data.normal_(0, 0.01)
              elif isinstance(m, nn.BatchNorm2d):
                  m.weight.data.fill_(1)
                  m.bias.data.zero_()
  
      # use torch.hub to load pretrained model
      if pretrained:
          pretrained_dict = torch.hub.load_state_dict_from_url(
              url, map_location=map_location_to_cpu
          )
          self.load_state_dict(pretrained_dict, strict=True)
      self.eval()
  
imports: import math
  from enum import Enum
  from typing import Dict, List, Optional, Tuple
  import torch
  import torch.nn.functional
  from torch import nn
  from kornia.geometry.bbox import nms
  from kornia.utils.helpers import map_location_to_cpu
label_desc: Use image node_id 1 to create a new YuFaceDetectNet object from inherited base classes: nn with example: obj = YuFaceDetectNet(phase, pretrained)