code: def _get_parameters(times, *params):
      """Gets parameter values at at specified `times`."""
      result = []
      for param in params:
          if isinstance(param, piecewise.PiecewiseConstantFunc):
              result.append(param(times))
          else:
              result.append(param * tf.ones_like(times))
      return result
  
file_path: tf-quant-finance/tf_quant_finance/models/heston/heston_model.py
imports: from typing import Union, Callable, Optional
  import numpy
  import tensorflow.compat.v2
  from tf_quant_finance import types
  from tf_quant_finance import utils
  from tf_quant_finance.math import piecewise
  from tf_quant_finance.math import random_ops
  from tf_quant_finance.models import generic_ito_process
  from tf_quant_finance.models import utils
label_desc: Use image node_id 1 for calling a global function with example usage: _get_parameters(times) and returns: result