code: def evaluate_interpolation(
      coefficients, t0, t1, t, validate_args=False
  ):
      """Evaluates the value of polynomial interpolation at the given time point.
  
      Args:
        coefficients: List of `Tensor`s that hold polynomial coefficients. Must have
          length greater or equal to 2.
        t0: Scalar floating `Tensor` giving the start of the interval.
        t1: Scalar floating `Tensor` giving the end of the interval.
        t: Scalar floating `Tensor` giving the desired interpolation point.
        validate_args: Python `bool` indicating whether to validate inputs.
          Default value: False.
  
      Returns:
        interpolated_value: Polynomial interpolation at time `t`.
  
      Raises:
        ValueError: If `coefficients` has less than 2 elements.
      """
      if len(coefficients) < 2:
          raise ValueError(
              "`coefficients` must have at least 2 elements."
          )
      with tf.name_scope("interp_evaluate"):
          dtype = dtype_util.common_dtype(coefficients)
          t0 = tf.convert_to_tensor(t0)
          t1 = tf.convert_to_tensor(t1)
          t = tf.convert_to_tensor(t)
          assert_ops = []
          if validate_args:
              assert_ops.append(
                  tf.Assert(
                      (t0 <= t) & (t <= t1),
                      [
                          "invalid interpolation, fails `t0 <= t <= t1`:",
                          t0,
                          t,
                          t1,
                      ],
                  )
              )
          with tf.control_dependencies(assert_ops):
              x = tf.cast((t - t0) / (t1 - t0), dtype)
          xs = [tf.constant(1, dtype), x]
          for _ in range(2, len(coefficients)):
              xs.append(xs[-1] * x)
          return weighted_sum(list(reversed(xs)), coefficients)
  
file_path: probability/tensorflow_probability/python/math/ode/runge_kutta_util.py
imports: import collections
  import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.internal import dtype_util
  from tensorflow_probability.python.internal import prefer_static
label_desc: Use image node_id 9 for calling a global function with example usage: evaluate_interpolation(coefficients, t0, t1, t, validate_args) and returns: weighted_sum