code: def __init__(
      self,
      inplanes,
      planes,
      stride=1,
      downsample=None,
      groups=1,
      base_width=64,
      dilation=1,
      norm_layer=None,
      kernel_size=56,
  ):
      super(AxialBlock, self).__init__()
      if norm_layer is None:
          norm_layer = nn.BatchNorm2d
      width = int(planes * (base_width / 64.0))
      # Both self.conv2 and self.downsample layers downsample the input when stride != 1
      self.conv_down = conv1x1(inplanes, width)
      self.bn1 = norm_layer(width)
      self.hight_block = AxialAttention(
          width, width, groups=groups, kernel_size=kernel_size
      )
      self.width_block = AxialAttention(
          width,
          width,
          groups=groups,
          kernel_size=kernel_size,
          stride=stride,
          width=True,
      )
      self.conv_up = conv1x1(width, planes * self.expansion)
      self.bn2 = norm_layer(planes * self.expansion)
      self.relu = nn.ReLU(inplace=True)
      self.downsample = downsample
      self.stride = stride
  
imports: import math
  import torch
  import torch.nn
  import torch.nn.functional
label_desc: Use image node_id 1 to create a new AxialBlock object from inherited base classes: nn with example: obj = AxialBlock(inplanes, planes, stride, downsample, groups, base_width, dilation, norm_layer, kernel_size)