class_docstr: SoftmaxCrossEntropyLoss with ignore labels
  
  Parameters
  ----------
  axis : int, default -1
      The axis to sum over when computing softmax and entropy.
  sparse_label : bool, default True
      Whether label is an integer array instead of probability distribution.
  from_logits : bool, default False
      Whether input is a log probability (usually from log_softmax) instead
      of unnormalized numbers.
  weight : float or None
      Global scalar weight for loss.
  batch_axis : int, default 0
      The axis that represents mini-batch.
  ignore_label : int, default -1
      The label to ignore.
  size_average : bool, default False
      Whether to re-scale loss with regard to ignored labels.
class_docstr_tok: ["SoftmaxCrossEntropyLoss","with","ignore","labels","Parameters","--","--","--","--","--","axis",":","int",",","default","-1","The","axis","to","sum","over","when","computing","softmax","and","entropy",".","sparse_label",":","bool",",","default","True","Whether","label","is","an","integer","array","instead","of","probability","distribution",".","from_logits",":","bool",",","default","False","Whether","input","is","a","log","probability","(","usually","from","log_softmax",")","instead","of","unnormalized","numbers",".","weight",":","float","or","None","Global","scalar","weight","for","loss",".","batch_axis",":","int",",","default","0","The","axis","that","represents","mini-batch",".","ignore_label",":","int",",","default","-1","The","label","to","ignore",".","size_average",":","bool",",","default","False","Whether","to","re-scale","loss","with","regard","to","ignored","labels","."]
docstr: Compute loss
docstr_tok: ["Compute","loss"]
code: def hybrid_forward(self, F, pred, label):
      """Compute loss"""
      softmaxout = F.contrib.SoftmaxOHEMOutput(
          pred,
          label.astype(pred.dtype),
          ignore_label=self._ignore_label,
          multi_output=self._sparse_label,
          use_ignore=True,
          normalization="valid" if self._size_average else "null",
          thresh=0.6,
          min_keep=256,
      )
      loss = -F.pick(F.log(softmaxout), label, axis=1, keepdims=True)
      loss = F.where(
          label.expand_dims(axis=1) == self._ignore_label,
          F.zeros_like(loss),
          loss,
      )
      return F.mean(loss, axis=self._batch_axis, exclude=True)
  
imports: from __future__ import absolute_import
  from mxnet import gluon
  from mxnet import nd
  from mxnet.gluon.loss import Loss, _apply_weighting, _reshape_like
label_desc: Use image node_id 2 for calling the SoftmaxCrossEntropyOHEMLoss obj's underlying member method code with example usage: obj.hybrid_forward(F, pred, label) and returns: F