parameters: (value, true_fn, false_fn)
docstring: Returns `true_fn() if value >= 0 else false_fn()`.
docstring_summary: Returns `true_fn() if value >= 0 else false_fn()`.
docstring_tokens: Returns true_fn () if value > = 0 else false_fn () .
function: def _if_ge_zero(value, true_fn, false_fn):
    """Returns `true_fn() if value >= 0 else false_fn()`."""
    # If `value` is statically known, then don't use a control flow op.
    if isinstance(value, ops.Tensor):
      const_value = tensor_util.constant_value(value)
      if const_value is None:
        return control_flow_ops.cond(value >= 0, true_fn, false_fn)
      else:
        value = const_value
    if value >= 0:
      return true_fn()
    else:
      return false_fn()
function_tokens: def _if_ge_zero ( value , true_fn , false_fn ) : # If `value` is statically known, then don't use a control flow op. if isinstance ( value , ops . Tensor ) : const_value = tensor_util . constant_value ( value ) if const_value is None : return control_flow_ops . cond ( value >= 0 , true_fn , false_fn ) else : value = const_value if value >= 0 : return true_fn ( ) else : return false_fn ( )