class_docstr: A subclass of :tf_main:`tf.layers.Layer <layers/Layer>`.
  A layer that consists of multiple layers connected sequentially.
  
  Args:
      layers (list): A list of :tf_main:`tf.layers.Layer
          <layers/layer>` instances, or a list of hyperparameter dicts
          each of which specifying type and kwargs of each layer (see
          the `hparams` argument of :func:`get_layer`). The layers are
          connected sequentially.
class_docstr_tok: ["A","subclass","of",":","tf_main",":","`","tf.layers.Layer","<","layers\/Layer",">","`",".","A","layer","that","consists","of","multiple","layers","connected","sequentially",".","Args",":","layers","(","list",")",":","A","list","of",":","tf_main",":","`","tf.layers.Layer","<","layers\/layer",">","`","instances",",","or","a","list","of","hyperparameter","dicts","each","of","which","specifying","type","and","kwargs","of","each","layer","(","see","the","`","hparams","`","argument","of",":","func",":","`","get_layer","`",")",".","The","layers","are","connected","sequentially","."]
code: def __init__(self, layers, trainable=True, name=None, **kwargs):
      super(SequentialLayer, self).__init__(
          trainable=trainable, name=name, **kwargs
      )
  
      if len(layers) == 0:
          raise ValueError("'layers' must be a non-empty list.")
      self._layers = []
      for layer in layers:
          if isinstance(layer, tf.layers.Layer):
              self._layers.append(layer)
          else:
              self._layers.append(get_layer(hparams=layer))
  
      # Keep tracks of whether trainable variables have been created
      self._vars_built = False
  
imports: import copy
  import tensorflow
  import tensorflow.contrib.rnn
  from texar.tf.hyperparams import HParams
  from texar.tf.utils import utils
  from texar.tf.utils.dtypes import is_str
  from texar.tf.utils.variables import add_variable
  from texar.tf.utils.mode import is_train_mode, switch_dropout
label_desc: Use image node_id 1 to create a new SequentialLayer object from inherited base classes: tf.layers with example: obj = SequentialLayer(layers, trainable, name)