code: def _make_layer(
      self,
      block,
      planes,
      blocks,
      stride=1,
      use_se=True,
      aa_layer=None,
      drop_path_rate=0.0,
  ):
      downsample = None
      if stride != 1 or self.inplanes != planes * block.expansion:
          layers = []
          if stride == 2:
              # avg pooling before 1x1 conv
              layers.append(
                  nn.AvgPool2d(
                      kernel_size=2,
                      stride=2,
                      ceil_mode=True,
                      count_include_pad=False,
                  )
              )
          layers += [
              ConvNormAct(
                  self.inplanes,
                  planes * block.expansion,
                  kernel_size=1,
                  stride=1,
                  apply_act=False,
                  act_layer=None,
              )
          ]
          downsample = nn.Sequential(*layers)
  
      layers = []
      for i in range(blocks):
          layers.append(
              block(
                  self.inplanes,
                  planes,
                  stride=stride if i == 0 else 1,
                  downsample=downsample if i == 0 else None,
                  use_se=use_se,
                  aa_layer=aa_layer,
                  drop_path_rate=drop_path_rate[i]
                  if isinstance(drop_path_rate, list)
                  else drop_path_rate,
              )
          )
          self.inplanes = planes * block.expansion
      return nn.Sequential(*layers)
  
imports: from collections import OrderedDict
  from functools import partial
  import torch
  import torch.nn
  from timm.layers import SpaceToDepth, BlurPool2d, ClassifierHead, SEModule, ConvNormActAa, ConvNormAct, DropPath
  from ._builder import build_model_with_cfg
  from ._manipulate import checkpoint_seq
  from ._registry import register_model, generate_default_cfgs, register_model_deprecations
label_desc: Use image node_id 2 for calling the TResNet obj's underlying member method code with example usage: obj._make_layer(block, planes, blocks, stride, use_se, aa_layer, drop_path_rate) and returns: nn