code: def hinge_embedding_loss(
      input,
      target,
      margin=1.0,
      size_average=None,
      reduce=None,
      reduction="mean",
  ):
      margin = ivy.array(margin)
  
      loss = ivy.where(
          ivy.logical_or(target == -1, target == 1),
          ivy.where(target == 1, input, ivy.maximum(0, margin - input)),
          ivy.maximum(margin, input),
      )
  
      reduction = _get_reduction(reduction, size_average, reduce)
      ret = reduction(loss)
  
      return ivy.astype(ret, input.dtype)
  
imports: import ivy
  import ivy.functional.frontends.torch
  from ivy.functional.frontends.torch.func_wrapper import to_ivy_arrays_and_back
  from ivy.func_wrapper import with_unsupported_dtypes, with_supported_dtypes
label_desc: Use image node_id 12 for calling a global function with example usage: hinge_embedding_loss(input, target, margin, size_average, reduce, reduction) and returns: ivy