code: def get_residualAttentionModel(
      input_size,
      num_layers,
      pretrained=None,
      ctx=None,
      root=None,
      **kwargs,
  ):
      r"""AttentionModel model from
      `"Residual Attention Network for Image Classification"
      <https://arxiv.org/pdf/1704.06904.pdf>`_ paper.
  
      Parameters
      ----------
      input_size : int
          Input size of net. Options are 32, 224.
      num_layers : int
          Numbers of layers. Options are 56, 92, 128, 164, 200, 236, 452.
      pretrained : bool, default False
          Whether to load the pretrained weights for model.
      ctx : Context, default CPU
          The context in which to load the pretrained weights.
      root : str, default '~/.mxnet/models'
          Location for keeping the model parameters.
      norm_layer : object
          Normalization layer used (default: :class:`mxnet.gluon.nn.BatchNorm`)
          Can be :class:`mxnet.gluon.nn.BatchNorm` or :class:`mxnet.gluon.contrib.nn.SyncBatchNorm`.
      norm_kwargs : dict
          Additional `norm_layer` arguments, for example `num_devices=4`
          for :class:`mxnet.gluon.contrib.nn.SyncBatchNorm`.
      """
      assert input_size in (32, 224)
      assert (
          num_layers in attention_spec
      ), "Invalid number of layers: %d. Options are %s" % (
          num_layers,
          str(attention_spec.keys()),
      )
      m, scale = attention_spec[num_layers]
      if input_size == 32:
          net = cifar_ResidualAttentionModel(scale, m, **kwargs)
      else:
          net = ResidualAttentionModel(scale, m, **kwargs)
      if pretrained:
          pass
  
      return net
  
imports: from mxnet.gluon import nn
  from mxnet.gluon.nn import BatchNorm
  from mxnet.gluon.block import HybridBlock
label_desc: Use image node_id 3 for calling a global function with example usage: get_residualAttentionModel(input_size, num_layers, pretrained, ctx, root) and returns: net