def _tfval_shape_dtype(val: TfVal) -> Tuple[(Sequence[Optional[int]], DType)]:
    'Called for constants that occur in the program, or for input values to the converted function.\n\n  The returned shape may have unknown components, but only when called for\n  inputs.\n  '
    if isinstance(val, (tf.Tensor, tf.Variable)):
        return (tuple(val.shape), to_jax_dtype(val.dtype))
    else:
        assert ((not config.jax_enable_checks) or _is_tfval(val)), f'Non TfVal: {val}'
        raw_aval = xla.abstractify(val)
        return (raw_aval.shape, raw_aval.dtype)
Called for constants that occur in the program, or for input values to the converted function.

The returned shape may have unknown components, but only when called for
inputs.
def _tfval_shape_dtype(val: TfVal) -> Tuple[(Sequence[Optional[int]], DType)]:
    'Called for constants that occur in the program, or for input values to the converted function.\n\n  The returned shape may have unknown components, but only when called for\n  inputs.\n  '
    if isinstance(val, (tf.Tensor, tf.Variable)):
        return (tuple(val.shape), to_jax_dtype(val.dtype))
    else:
        assert ((not config.jax_enable_checks) or _is_tfval(val)), f'Non TfVal: {val}'
        raw_aval = xla.abstractify(val)
        return (raw_aval.shape, raw_aval.dtype)