docstr: Parameters
  ----------
  true
      input array containing true labels.
  pred
      input array containing Predicted labels.
  from_logits
      Whether `pred` is expected to be a logits tensor. By
      default, we assume that `pred` encodes a probability distribution.
  epsilon
      a float in [0.0, 1.0] specifying the amount of smoothing when calculating
      the loss. If epsilon is ``0``, no smoothing will be applied. Default: ``0``.
  reduction
      ``'none'``: No reduction will be applied to the output.
      ``'mean'``: The output will be averaged.
      ``'sum'``: The output will be summed. Default: ``'none'``.
  pos_weight
      a weight for positive examples. Must be an array with length equal to the
      number of classes.
  axis
      Axis along which to compute crossentropy.
  
  Returns
  -------
  ret
      The binary cross entropy between the given distributions.
docstr_tok: ["Parameters","--","--","--","--","--","true","input","array","containing","true","labels",".","pred","input","array","containing","Predicted","labels",".","from_logits","Whether","`","pred","`","is","expected","to","be","a","logits","tensor",".","By","default",",","we","assume","that","`","pred","`","encodes","a","probability","distribution",".","epsilon","a","float","in","[","0.0",",","1.0","]","specifying","the","amount","of","smoothing","when","calculating","the","loss",".","If","epsilon","is","``","0","``",",","no","smoothing","will","be","applied",".","Default",":","``","0","``",".","reduction","``","'none","'","``",":","No","reduction","will","be","applied","to","the","output",".","``","'mean","'","``",":","The","output","will","be","averaged",".","``","'sum","'","``",":","The","output","will","be","summed",".","Default",":","``","'none","'","``",".","pos_weight","a","weight","for","positive","examples",".","Must","be","an","array","with","length","equal","to","the","number","of","classes",".","axis","Axis","along","which","to","compute","crossentropy",".","Returns","--","--","--","-","ret","The","binary","cross","entropy","between","the","given","distributions","."]
code: def _forward(
      self,
      true,
      pred,
      *,
      from_logits=None,
      epsilon=None,
      reduction=None,
      pos_weight=None,
      axis=None,
  ):
      """
      Parameters
      ----------
      true
          input array containing true labels.
      pred
          input array containing Predicted labels.
      from_logits
          Whether `pred` is expected to be a logits tensor. By
          default, we assume that `pred` encodes a probability distribution.
      epsilon
          a float in [0.0, 1.0] specifying the amount of smoothing when calculating
          the loss. If epsilon is ``0``, no smoothing will be applied. Default: ``0``.
      reduction
          ``'none'``: No reduction will be applied to the output.
          ``'mean'``: The output will be averaged.
          ``'sum'``: The output will be summed. Default: ``'none'``.
      pos_weight
          a weight for positive examples. Must be an array with length equal to the
          number of classes.
      axis
          Axis along which to compute crossentropy.
  
      Returns
      -------
      ret
          The binary cross entropy between the given distributions.
      """
      return ivy.binary_cross_entropy(
          true,
          pred,
          from_logits=ivy.default(from_logits, self._from_logits),
          epsilon=ivy.default(epsilon, self._epsilon),
          reduction=ivy.default(reduction, self._reduction),
          pos_weight=pos_weight,
          axis=axis,
      )
  
file_path: ivy/ivy/stateful/losses.py
imports: import ivy
  from ivy.stateful.module import Module
label_desc: Use image node_id 2 for calling the BinaryCrossEntropyLoss obj's underlying member method code with example usage: obj._forward(true, pred) and returns: ivy