class_docstr: AnyNet model.
class_docstr_tok: ["AnyNet","model","."]
code: def __init__(self, params=None):
      super(AnyNet, self).__init__()
      p = AnyNet.get_params() if not params else params
      stem_fun = get_stem_fun(p["stem_type"])
      block_fun = get_block_fun(p["block_type"])
      self.stem = stem_fun(3, p["stem_w"])
      prev_w = p["stem_w"]
      keys = ["depths", "widths", "strides", "bot_muls", "group_ws"]
      for i, (d, w, s, b, g) in enumerate(zip(*[p[k] for k in keys])):
          params = {"bot_mul": b, "group_w": g, "se_r": p["se_r"]}
          stage = AnyStage(prev_w, w, s, d, block_fun, params)
          self.add_module("s{}".format(i + 1), stage)
          prev_w = w
      self.head = AnyHead(prev_w, p["head_w"], p["num_classes"])
      self.apply(init_weights)
  
imports: from pycls.core.config import cfg
  from pycls.models.blocks import activation, conv2d, conv2d_cx, gap2d, gap2d_cx, init_weights, linear, linear_cx, norm2d, norm2d_cx, pool2d, pool2d_cx, SE
  from torch.nn import Module
label_desc: Use image node_id 2 to create a new AnyNet object from inherited base classes: Module with example: obj = AnyNet(params)