parameters: (dtype, ignore_value=None)
return_statement: return math_ops.cast(ignore_value, dtype, name="ignore_value")
docstring: Create `Tensor` from provided `ignore_value` and  `dtype`.
docstring_summary: Create `Tensor` from provided `ignore_value` and  `dtype`.
docstring_tokens: Create Tensor from provided ignore_value and dtype .
function: def _ignore_value_tensor(dtype, ignore_value=None):
    """Create `Tensor` from provided `ignore_value` and  `dtype`."""
    if ignore_value is None:
      if dtype == dtypes.string:
        # Exception due to TF strings are converted to numpy objects by default.
        ignore_value = ""
      else:
        # NOTE: `as_numpy_dtype` is a property, so with the parentheses this is
        # constructing a new numpy object of the given type, which yields the
        # default value for that type.
        ignore_value = dtype.as_numpy_dtype()
    return math_ops.cast(ignore_value, dtype, name="ignore_value")
function_tokens: def _ignore_value_tensor ( dtype , ignore_value = None ) : if ignore_value is None : if dtype == dtypes . string : # Exception due to TF strings are converted to numpy objects by default. ignore_value = "" else : # NOTE: `as_numpy_dtype` is a property, so with the parentheses this is # constructing a new numpy object of the given type, which yields the # default value for that type. ignore_value = dtype . as_numpy_dtype ( ) return math_ops . cast ( ignore_value , dtype , name = "ignore_value" )