class_docstr: The search space proposed in `Single Path One-shot <https://www.ecva.net/papers/eccv_2020/papers_ECCV/papers/123610528.pdf>`__.
  
  The basic building block design is inspired by a state-of-the-art manually-designed network --
  `ShuffleNetV2 <https://openaccess.thecvf.com/content_ECCV_2018/html/Ningning_Light-weight_CNN_Architecture_ECCV_2018_paper.html>`__.
  There are 20 choice blocks in total. Each choice block has 4 candidates, namely ``choice 3``, ``choice 5``,
  ``choice_7`` and ``choice_x`` respectively. They differ in kernel sizes and the number of depthwise convolutions.
  The size of the search space is :math:`4^{20}`.
  
  Parameters
  ----------
  num_labels : int
      Number of classes for the classification head. Default: 1000.
  channel_search : bool
      If true, for each building block, the number of ``mid_channels``
      (output channels of the first 1x1 conv in each building block) varies from 0.2x to 1.6x (quantized to multiple of 0.2).
      Here, "k-x" means k times the number of default channels.
      Otherwise, 1.0x is used by default. Default: false.
  affine : bool
      Apply affine to all batch norm. Default: true.
code: def load_searched_model(
      cls,
      name: str,
      pretrained: bool = False,
      download: bool = False,
      progress: bool = True,
  ) -> nn.Module:
      if name == "spos":
          # NOTE: Need BGR tensor, with no normalization
          # https://github.com/ultmaster/spacehub-conversion/blob/371a4fd6646b4e11eda3f61187f7c9a1d484b1ca/cutils.py#L63
          arch = {
              "layer_1": "k7",
              "layer_2": "k5",
              "layer_3": "k3",
              "layer_4": "k5",
              "layer_5": "k7",
              "layer_6": "k3",
              "layer_7": "k7",
              "layer_8": "k3",
              "layer_9": "k7",
              "layer_10": "k3",
              "layer_11": "k7",
              "layer_12": "xcep",
              "layer_13": "k3",
              "layer_14": "k3",
              "layer_15": "k3",
              "layer_16": "k3",
              "layer_17": "xcep",
              "layer_18": "k7",
              "layer_19": "xcep",
              "layer_20": "xcep",
          }
  
      else:
          raise ValueError(
              f"Unsupported architecture with name: {name}"
          )
  
      model_factory = cls.frozen_factory(arch)
      model = model_factory()
  
      if pretrained:
          weight_file = load_pretrained_weight(
              name, download=download, progress=progress
          )
          pretrained_weights = torch.load(weight_file)
          model.load_state_dict(pretrained_weights)
  
      return model
  
imports: from typing import Union, cast
  import torch
  import torch.nn
  import nni
  from nni.mutable import MutableExpression
  from nni.nas.nn.pytorch import LayerChoice, ModelSpace, MutableConv2d, MutableBatchNorm2d
  from .utils.pretrained import load_pretrained_weight
label_desc: Use image node_id 4 for calling the ShuffleNetSpace obj's underlying member method code with example usage: obj.load_searched_model(cls, name, pretrained, download, progress) and returns: model