code: def _binary_matches(y_true, y_pred, threshold=0.5):
      threshold = ivy.astype(ivy.array(threshold), y_pred.dtype)
      y_pred = ivy.astype(ivy.greater(y_pred, threshold), y_pred.dtype)
      return ivy.astype(
          ivy.equal(y_true, y_pred),
          ivy.default_float_dtype(as_native=True),
      )
  
imports: import ivy
  from ivy.functional.frontends.tensorflow.func_wrapper import to_ivy_arrays_and_back
label_desc: Use image node_id 1 for calling a global function with example usage: _binary_matches(y_true, y_pred, threshold) and returns: ivy