class_docstr: This class defines core TCN architecture.
  This is only the base class, training strategy is not implemented.
docstr: To use this class,
      1. Inherit this class
      2. Define the training losses in build_train_graph()
      3. Define the training strategy in run()
      4. After the inherited class object is initialized,
         call build_train_graph followed by run
  
  Args:
      max_len: Maximum length of sequence
      n_features_in: Number of input features (dimensions)
      hidden_sizes: Number of hidden sizes in each layer of TCN (same for all layers)
      kernel_size: Kernel size of convolution filter (same for all layers)
      dropout: Dropout, fraction of activations to drop
docstr_tok: ["To","use","this","class",",","1",".","Inherit","this","class","2",".","Define","the","training","losses","in","build_train_graph","(",")","3",".","Define","the","training","strategy","in","run","(",")","4",".","After","the","inherited","class","object","is","initialized",",","call","build_train_graph","followed","by","run","Args",":","max_len",":","Maximum","length","of","sequence","n_features_in",":","Number","of","input","features","(","dimensions",")","hidden_sizes",":","Number","of","hidden","sizes","in","each","layer","of","TCN","(","same","for","all","layers",")","kernel_size",":","Kernel","size","of","convolution","filter","(","same","for","all","layers",")","dropout",":","Dropout",",","fraction","of","activations","to","drop"]
code: def __init__(
      self,
      max_len,
      n_features_in,
      hidden_sizes,
      kernel_size=7,
      dropout=0.2,
  ):
      """
      To use this class,
          1. Inherit this class
          2. Define the training losses in build_train_graph()
          3. Define the training strategy in run()
          4. After the inherited class object is initialized,
             call build_train_graph followed by run
  
      Args:
          max_len: Maximum length of sequence
          n_features_in: Number of input features (dimensions)
          hidden_sizes: Number of hidden sizes in each layer of TCN (same for all layers)
          kernel_size: Kernel size of convolution filter (same for all layers)
          dropout: Dropout, fraction of activations to drop
      """
      self.max_len = max_len
      self.n_features_in = n_features_in
      self.hidden_sizes = hidden_sizes
      self.kernel_size = kernel_size
      self.dropout = dropout
      self.n_hidden_layers = len(self.hidden_sizes)
      receptive_field_len = self.calculate_receptive_field()
      if receptive_field_len < self.max_len:
          print(
              "Warning! receptive field of the TCN: "
              "%d is less than the input sequence length: %d."
              % (receptive_field_len, self.max_len)
          )
      else:
          print(
              "Receptive field of the TCN: %d, input sequence length: %d."
              % (receptive_field_len, self.max_len)
          )
      self.layer_activations = []
  
      # toggle this for train/inference mode
      self.training_mode = tf.placeholder(tf.bool, name="training_mode")
  
      self.sequence_output = None
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow
  from tensorflow.python.framework import tensor_shape
  from tensorflow.python.keras.layers import Wrapper
  from tensorflow.python.layers.convolutional import Conv1D
  from tensorflow.python.ops import variable_scope
  from tensorflow.python.keras.engine.base_layer import Layer
  from tensorflow.python.eager import context
  from tensorflow.python.ops import nn_impl
  from tensorflow.python.keras import initializers
  from tensorflow.python.keras.engine.base_layer import InputSpec
  from tensorflow.python.ops import array_ops
  from tensorflow.python.framework import ops
label_desc: Use image node_id 1 to create a new TCN object  with example: obj = TCN(max_len, n_features_in, hidden_sizes, kernel_size, dropout)