code: def set_standard_dense_net(
      self,
      data_provider: DataProvider,
      growth_rate,
      depth,
      total_blocks,
      keep_prob,
      weight_decay,
      model_type,
      first_ratio=2,
      reduction=1.0,
      bc_ratio=4,
      bn_epsilon=1e-5,
      bn_decay=0.9,
      print_info=True,
      pre_activation=True,
      **kwargs,
  ):
      self.net_config = {
          "model_type": model_type,
          "weight_decay": weight_decay,
          "first_ratio": first_ratio,
          "reduction": reduction,
          "bc_ratio": bc_ratio,
          "bn_epsilon": bn_epsilon,
          "bn_decay": bn_decay,
          "pre_activation": pre_activation,
      }
  
      image_size = data_provider.data_shape[0]
  
      first_output_features = growth_rate * first_ratio
      bc_mode = model_type == "DenseNet-BC"
      layers_per_block = (depth - (total_blocks + 1)) // total_blocks
      if bc_mode:
          layers_per_block = layers_per_block // 2
  
      # initial conv
      if pre_activation:
          init_conv_layer = ConvLayer(
              "conv_0",
              first_output_features,
              kernel_size=3,
              activation=None,
              use_bn=False,
          )
      else:
          init_conv_layer = ConvLayer(
              "conv_0",
              first_output_features,
              kernel_size=3,
              pre_activation=False,
          )
      init_transition = TransitionBlock("T_0_first", [init_conv_layer])
      self.blocks = [init_transition]
  
      # Dense Blocks
      in_features_dim = first_output_features
      for block_idx in range(1, total_blocks + 1):
          miniblocks = []
          block_id = "D_%d" % block_idx
          for miniblock_idx in range(1, layers_per_block + 1):
              miniblock_id = "M_%d" % miniblock_idx
              in_bottle = None
              if bc_mode:
                  bottelneck_layer = ConvLayer(
                      "conv_0",
                      growth_rate * bc_ratio,
                      kernel_size=1,
                      keep_prob=keep_prob,
                      pre_activation=pre_activation,
                  )
                  in_bottle = LayerCascade(
                      "in_bottle", [bottelneck_layer]
                  )
  
              branch_0 = LayerCascade(
                  "B_0",
                  [
                      ConvLayer(
                          "conv_0",
                          growth_rate,
                          kernel_size=3,
                          keep_prob=keep_prob,
                          pre_activation=pre_activation,
                      )
                  ],
              )
              miniblocks.append(
                  LayerMultiBranch(
                      miniblock_id, [branch_0], in_bottle=in_bottle
                  )
              )
          dense_block = DenseBlock(block_id, miniblocks)
          self.blocks += [dense_block]
  
          out_features_dim = dense_block.out_features_dim(
              in_features_dim
          )
          if block_idx != total_blocks:
              out_features_dim = int(out_features_dim * reduction)
              transition_id = "T_%d_middle" % block_idx
              conv_layer = ConvLayer(
                  "conv_0",
                  out_features_dim,
                  kernel_size=1,
                  keep_prob=keep_prob,
                  pre_activation=pre_activation,
              )
              avg_pool_layer = PoolLayer(
                  "pool_0", "avg", kernel_size=2, strides=2
              )
              transition = TransitionBlock(
                  transition_id, [conv_layer, avg_pool_layer]
              )
              self.blocks.append(transition)
              image_size = image_size // 2
          in_features_dim = out_features_dim
  
      # Transition to classes
      if pre_activation:
          global_avg_pool = PoolLayer(
              "pool_0",
              "avg",
              kernel_size=image_size,
              strides=image_size,
              activation="relu",
              use_bn=True,
          )
      else:
          global_avg_pool = PoolLayer(
              "pool_0",
              "avg",
              kernel_size=image_size,
              strides=image_size,
              pre_activation=False,
          )
      final_fc_layer = FCLayer(
          "fc_0",
          data_provider.n_classes,
          use_bn=False,
          use_bias=True,
          activation=None,
      )
      transition_to_classes = TransitionBlock(
          "T_to_classes", [global_avg_pool, final_fc_layer]
      )
      self.blocks.append(transition_to_classes)
  
      # print information about the network
      if print_info:
          print("Set Standard %s" % model_type)
  
          if not bc_mode:
              print(
                  "Build %s model with %d blocks, "
                  "%d composite layers each."
                  % (model_type, total_blocks, layers_per_block)
              )
          if bc_mode:
              print(
                  "Build %s model with %d blocks, "
                  "%d bottleneck layers and %d composite layers each."
                  % (
                      model_type,
                      total_blocks,
                      layers_per_block,
                      layers_per_block,
                  )
              )
          print("Reduction at transition layers: %.2f" % reduction)
      return self
  
imports: import tensorflow
  from .basic_model import BasicModel
  from .layers import ConvLayer, FCLayer, PoolLayer, get_magnifier, apply_noise
  from ..data_providers.base_provider import DataProvider
  from .layer_cascade import LayerCascade
  from .layer_multi_branch import LayerMultiBranch
  import numpy
label_desc: Use image node_id 14 for calling the DenseNetConfig obj's underlying member method code with example usage: obj.set_standard_dense_net(data_provider, growth_rate, depth, total_blocks, keep_prob, weight_decay, model_type, first_ratio, reduction, bc_ratio, bn_epsilon, bn_decay, print_info, pre_activation) and returns: self