class_docstr: ### Description
      A reimplementation of 2D UNet:
          Ronneberger et al., U-Net: Convolutional Networks for Biomedical
          Image Segmentation, MICCAI '15
  
  ### Building blocks
  [dBLOCK]        - Downsampling Block (conv 3x3, Relu + conv 3x3, Relu +  Max pooling)
  [BLOCK]         - Two layer Block (conv 3x3, Relu + conv 3x3, Relu)
  [uBLOCK]        - Upsampling Block (deconv 2x2 + crop and concat + conv 3x3, Relu + conv 3x3, Relu)
  [CONV]          - Classification block (conv 1x1)
  
  ### Diagram
  
  INPUT  -->  [dBLOCK] - - - - - - - - - - - - - - - -  [BLOCK] --> [CONV] --> OUTPUT
                  |                                       |
                  [dBLOCK] - - - - - - - - - - - - [uBLOCK]
                      |                              |
                      [dBLOCK]  - - - - - - - [uBLOCK]
                          |                      |
                          [dBLOCK]  - - - [uBLOCK]
                              |               |
                              ----[BLOCk] ----
  
  ### Constraints
code: def __init__(
      self,
      num_classes,
      w_initializer=None,
      w_regularizer=None,
      b_initializer=None,
      b_regularizer=None,
      acti_func="relu",
      name="UNet2D",
  ):
      BaseNet.__init__(self, num_classes=num_classes, name=name)
      self.n_fea = [64, 128, 256, 512, 1024]
  
      net_params = {
          "padding": "VALID",
          "with_bias": True,
          "feature_normalization": "batch",
          "group_size": -1,
          "acti_func": acti_func,
          "w_initializer": w_initializer,
          "b_initializer": b_initializer,
          "w_regularizer": w_regularizer,
          "b_regularizer": b_regularizer,
      }
  
      self.conv_params = {"kernel_size": 3, "stride": 1}
      self.deconv_params = {"kernel_size": 2, "stride": 2}
      self.pooling_params = {"kernel_size": 2, "stride": 2}
  
      self.conv_params.update(net_params)
      self.deconv_params.update(net_params)
  
imports: from __future__ import absolute_import, print_function
  import tensorflow
  from niftynet.layer.base_layer import TrainableLayer, Layer
  from niftynet.layer.convolution import ConvolutionalLayer
  from niftynet.layer.crop import CropLayer
  from niftynet.layer.deconvolution import DeconvolutionalLayer
  from niftynet.layer.downsample import DownSampleLayer
  from niftynet.layer.elementwise import ElementwiseLayer
  from niftynet.layer.linear_resize import LinearResizeLayer
  from niftynet.network.base_net import BaseNet
label_desc: Use image node_id 1 to create a new UNet2D object from inherited base classes: BaseNet with example: obj = UNet2D(num_classes, w_initializer, w_regularizer, b_initializer, b_regularizer, acti_func, name)