class_docstr: Wrapper for tf.data.Dataset to permit extensions.
class_docstr_tok: ["Wrapper","for","tf.data.Dataset","to","permit","extensions","."]
code: def from_arrays(cls, images: np.ndarray, labels: np.ndarray):
      return cls(
          tf.data.Dataset.from_tensor_slices(
              dict(
                  image=images,
                  label=labels,
                  index=np.arange(images.shape[0], dtype=np.int64),
              )
          ),
          images.shape[1:],
          parse_fn=None,
      )
  
imports: import os
  from typing import Callable, Optional, Tuple, List, Iterable
  import numpy
  import tensorflow
  from absl import flags
label_desc: Use image node_id 2 for calling the DataSet obj's underlying member method code with example usage: obj.from_arrays(cls, images, labels) and returns: cls