class_docstr: A `Dataset` that groups its input and performs a windowed reduction.
docstr: Make wrapping defun for reduce_func.
docstr_tok: ["Make","wrapping","defun","for","reduce_func","."]
code: def _make_reduce_func(self, reduce_func, input_dataset):
      """Make wrapping defun for reduce_func."""
      nested_dataset = dataset_ops.DatasetSpec(
          input_dataset.element_spec
      )
      input_structure = (
          tensor_spec.TensorSpec([], dtypes.int64),
          nested_dataset,
      )
      self._reduce_func = structured_function.StructuredFunctionWrapper(
          reduce_func,
          self._transformation_name(),
          input_structure=input_structure,
      )
      if not isinstance(
          self._reduce_func.output_structure, dataset_ops.DatasetSpec
      ):
          raise TypeError(
              f"Invalid `reduce_func`. `reduce_func` must return a "
              f"single `tf.data.Dataset` object but its return type "
              f"is {self._reduce_func.output_structure}."
          )
      # pylint: disable=protected-access
      self._element_spec = (
          self._reduce_func.output_structure._element_spec
      )
  
file_path: tensorflow-upstream/tensorflow/python/data/ops/group_by_window_op.py
imports: from tensorflow.python.data.ops import dataset_ops
  from tensorflow.python.data.ops import structured_function
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import tensor_spec
  from tensorflow.python.ops import gen_experimental_dataset_ops
label_desc: Use image node_id 4 for calling the _GroupByWindowDataset obj's underlying member method code with example usage: obj._make_reduce_func(reduce_func, input_dataset) without return types