mmocr.models.common.losses.ce_loss 源代码
# Copyright (c) OpenMMLab. All rights reserved.
import torch.nn as nn
from mmocr.registry import MODELS
[文档]@MODELS.register_module()
class CrossEntropyLoss(nn.CrossEntropyLoss):
"""Cross entropy loss."""