class_docstr: A `Dataset` that maps a function over elements in its input.
code: def __init__(
      self,
      input_dataset,
      map_func,
      use_inter_op_parallelism=True,
      preserve_cardinality=True,
      use_legacy_function=False,
      name=None,
  ):
      self._input_dataset = input_dataset
      self._use_inter_op_parallelism = use_inter_op_parallelism
      self._preserve_cardinality = preserve_cardinality
      self._map_func = structured_function.StructuredFunctionWrapper(
          map_func,
          self._transformation_name(),
          dataset=input_dataset,
          use_legacy_function=use_legacy_function,
      )
      self._name = name
      variant_tensor = gen_dataset_ops.map_dataset(
          input_dataset._variant_tensor,  # pylint: disable=protected-access
          self._map_func.function.captured_inputs,
          f=self._map_func.function,
          use_inter_op_parallelism=self._use_inter_op_parallelism,
          preserve_cardinality=self._preserve_cardinality,
          **self._common_args,
      )
      super().__init__(input_dataset, variant_tensor)
  
imports: import warnings
  from tensorflow.python.data.ops import dataset_ops
  from tensorflow.python.data.ops import debug_mode
  from tensorflow.python.data.ops import structured_function
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.ops import gen_dataset_ops
label_desc: Use image node_id 1 to create a new _MapDataset object from inherited base classes: dataset_ops with example: obj = _MapDataset(input_dataset, map_func, use_inter_op_parallelism, preserve_cardinality, use_legacy_function, name)