code: def _add_mxnet_ctc_loss(pred, seq_len, label):
      
      pred_ctc = mx.sym.Reshape(data=pred, shape=(-4, seq_len, -1, 0))
  
      loss = mx.sym.contrib.ctc_loss(data=pred_ctc, label=label)
      ctc_loss = mx.sym.MakeLoss(loss)
  
      softmax_class = mx.symbol.SoftmaxActivation(data=pred)
      softmax_loss = mx.sym.MakeLoss(softmax_class)
      softmax_loss = mx.sym.BlockGrad(softmax_loss)
      return mx.sym.Group([softmax_loss, ctc_loss])
docs: Adds Symbol.WapCTC on top of pred symbol and returns the resulting symbol