class_docstr: ### Description
      implementation of Res-Net:
        He et al., "Identity Mappings in Deep Residual Networks", arXiv:1603.05027v3
  
  ### Building Blocks
  [CONV]          - Convolutional layer, no activation, no batch norm
  (s)[DOWNRES]    - Downsample residual block.
                      Each block is composed of a first bottleneck block with stride s,
                      followed by n_blocks_per_resolution bottleneck blocks with stride 1.
  [FC]            - Fully connected layer with nr output channels == num_classes
  
  ### Diagram
  
  INPUT --> [CONV] -->(s=1)[DOWNRES] --> (s=2)[DOWNRES]x2 --> BN, ReLU, mean --> [FC] --> OUTPUT
  
  ### Constraints
docstr: :param images: tensor, input to the network
  :param is_training: boolean, True if network is in training mode
  :param unused_kwargs: not in use
  :return: tensor, output of the final fully connected layer
docstr_tok: [":","param","images",":","tensor",",","input","to","the","network",":","param","is_training",":","boolean",",","True","if","network","is","in","training","mode",":","param","unused_kwargs",":","not","in","use",":","return",":","tensor",",","output","of","the","final","fully","connected","layer"]
code: def layer_op(self, images, is_training=True, **unused_kwargs):
      """
  
      :param images: tensor, input to the network
      :param is_training: boolean, True if network is in training mode
      :param unused_kwargs: not in use
      :return: tensor, output of the final fully connected layer
      """
      layers = self.create()
      out = layers.conv1(images, is_training)
      for block in layers.blocks:
          out = block(out, is_training)
  
      spatial_rank = layer_util.infer_spatial_rank(out)
      axis_to_avg = [dim + 1 for dim in range(spatial_rank)]
      out = tf.reduce_mean(
          tf.nn.relu(layers.bn(out, is_training)), axis=axis_to_avg
      )
      return layers.fc(out)
  
imports: from __future__ import absolute_import, print_function
  import functools
  from collections import namedtuple
  import tensorflow
  from niftynet.layer import layer_util
  from niftynet.layer.base_layer import TrainableLayer
  from niftynet.layer.bn import BNLayer
  from niftynet.layer.convolution import ConvolutionalLayer
  from niftynet.layer.fully_connected import FCLayer
  from niftynet.network.base_net import BaseNet
label_desc: Use image node_id 3 for calling the ResNet obj's underlying member method code with example usage: obj.layer_op(images, is_training) and returns: layers