code: def test_data_input_to_tensor() -> None:
      input1 = (1.0, (2.0,))
      output1 = data_input_to_tensor(input1)
      assert output1[0].dtype == tf.float64
      assert output1[1][0].dtype == tf.float64
  
      input2 = (1.0, [2.0])
      output2 = data_input_to_tensor(input2)
      assert output2[0].dtype == tf.float64
      assert output2[1][0].dtype == tf.float64
  
      input3: Tuple[float, Tuple[AnyNDArray, AnyNDArray]] = (
          1.0,
          (np.arange(3, dtype=np.float16),) * 2,
      )
      output3 = data_input_to_tensor(input3)
      assert output3[0].dtype == tf.float64
      assert output3[1][0].dtype == tf.float16
      assert output3[1][1].dtype == tf.float16
  
file_path: GPflow/tests/gpflow/utilities/test_utilities.py
imports: from typing import Tuple
  import numpy
  import tensorflow
  import tensorflow_probability
  import gpflow
  from gpflow.base import AnyNDArray
  from gpflow.models.util import data_input_to_tensor
label_desc: Use image node_id 2 for calling a global function with example usage: test_data_input_to_tensor() without return types