class_docstr: Pooling layer for arbitrary reduce functions for 1D inputs.
  
  The same as `tf.python.layers.pooling._Pooling1D` except that the pooling
  dimension is entirely reduced (i.e., `pool_size=length`).
  
  This class is for code reuse, rather than an exposed API.
class_docstr_tok: ["Pooling","layer","for","arbitrary","reduce","functions","for","1D","inputs",".","The","same","as","`","tf.python.layers.pooling._Pooling1D","`","except","that","the","pooling","dimension","is","entirely","reduced","(","i.e.",",","`","pool_size=length","`",")",".","This","class","is","for","code","reuse",",","rather","than","an","exposed","API","."]
code: def __init__(
      self,
      reduce_function,
      data_format="channels_last",
      name=None,
      **kwargs,
  ):
      super(_ReducePooling1D, self).__init__(name=name, **kwargs)
      self._reduce_function = reduce_function
      if data_format not in {"channels_last", "channels_first"}:
          raise ValueError(
              "`data_format must be either 'channels_last' or` "
              "'channels_first'. Got: {}".format(data_format)
          )
      self._data_format = data_format
  
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 _ReducePooling1D object from inherited base classes: tf.layers with example: obj = _ReducePooling1D(reduce_function, data_format, name)