docstr: Converts a NumPy ndarray batch to the tensor type for the DL framework.
  
  Args:
      numpy_array: The numpy array to convert to a tensor.
      dtype: The tensor dtype to use when creating the DL tensor.
      ndarray: A (dict of) NumPy ndarray(s) that we wish to convert to a (dict of)
          tensor(s).
      dtype: A (dict of) tensor dtype(s) to use when creating the DL tensor; if
          None, the dtype will be inferred from the NumPy ndarray data.
  
  Returns:
      A deep learning framework specific tensor.
docstr_tok: ["Converts","a","NumPy","ndarray","batch","to","the","tensor","type","for","the","DL","framework",".","Args",":","numpy_array",":","The","numpy","array","to","convert","to","a","tensor",".","dtype",":","The","tensor","dtype","to","use","when","creating","the","DL","tensor",".","ndarray",":","A","(","dict","of",")","NumPy","ndarray","(","s",")","that","we","wish","to","convert","to","a","(","dict","of",")","tensor","(","s",")",".","dtype",":","A","(","dict","of",")","tensor","dtype","(","s",")","to","use","when","creating","the","DL","tensor",";","if","None",",","the","dtype","will","be","inferred","from","the","NumPy","ndarray","data",".","Returns",":","A","deep","learning","framework","specific","tensor","."]
code: def _arrays_to_tensors(
      self,
      numpy_arrays: Union[np.ndarray, Dict[str, np.ndarray]],
      dtype: Optional[Union[TensorDtype, Dict[str, TensorDtype]]],
  ) -> Union[TensorType, Dict[str, TensorType]]:
      """Converts a NumPy ndarray batch to the tensor type for the DL framework.
  
      Args:
          numpy_array: The numpy array to convert to a tensor.
          dtype: The tensor dtype to use when creating the DL tensor.
          ndarray: A (dict of) NumPy ndarray(s) that we wish to convert to a (dict of)
              tensor(s).
          dtype: A (dict of) tensor dtype(s) to use when creating the DL tensor; if
              None, the dtype will be inferred from the NumPy ndarray data.
  
      Returns:
          A deep learning framework specific tensor.
      """
      raise NotImplementedError
  
file_path: ray/python/ray/train/_internal/dl_predictor.py
imports: import abc
  from typing import Dict, Optional, TypeVar, Union
  import numpy
  import pandas
  from ray.air.util.data_batch_conversion import BatchFormat, _convert_batch_type_to_pandas, _convert_pandas_to_batch_type
  from ray.train.predictor import Predictor
  from ray.util.annotations import DeveloperAPI
label_desc: Use image node_id 1 for calling the DLPredictor obj's underlying member method code with example usage: obj._arrays_to_tensors(numpy_arrays, dtype) without return types