code: def deep_core(
      control_name,
      control_config,
      num_layers=1,
      skip_connections=True,
      name=None,
  ):
      """Constructs a deep control module.
  
      Args:
        control_name: Name of control module (e.g. "LSTM").
        control_config: Dictionary containing the configuration for the modules.
        num_layers: Number of layers.
        skip_connections: Boolean that indicates whether to use skip connections.
          See documenation for sonnet.DeepRnn in
          //learning/deepmind/tensorflow/sonnet/python/modules/basic_rnn.py for more
          information.
        name: module name.
  
      Returns:
        Deep control module.
      """
      control_class = get_controller_ctor(control_name)
      cores = [
          control_class(
              name="{}_{}".format(control_name, i), **control_config
          )
          for i in range(num_layers)
      ]
      if skip_connections:
          return recurrent.deep_rnn_with_skip_connections(
              cores, name=name
          )
      else:
          return recurrent.DeepRNN(cores, name=name)
  
file_path: sonnet/sonnet/src/nets/dnc/control.py
imports: import sys
  from sonnet.src import linear
  from sonnet.src import recurrent
  import tensorflow
label_desc: Use image node_id 2 for calling a global function with example usage: deep_core(control_name, control_config, num_layers, skip_connections, name) and returns: recurrent, recurrent