CRNN_Chinese_Characters_Rec icon indicating copy to clipboard operation
CRNN_Chinese_Characters_Rec copied to clipboard

ctc loss error

Open daeing opened this issue 3 years ago • 0 comments

loss = criterion(preds, text, tuple(preds_size), length) File "/opt/conda/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1110, in _call_impl return forward_call(*input, **kwargs) File "/opt/conda/lib/python3.8/site-packages/torch/nn/modules/loss.py", line 1714, in forward return F.ctc_loss(log_probs, targets, input_lengths, target_lengths, self.blank, self.reduction, File "/opt/conda/lib/python3.8/site-packages/torch/nn/functional.py", line 2559, in ctc_loss return torch.ctc_loss( RuntimeError: input_lengths must be of size batch_size

daeing avatar Dec 23 '21 10:12 daeing