(beta)torch_npu.contrib.module.LabelSmoothingCrossEntropy
函数原型
[object Object]
功能说明
使用NPU API进行LabelSmoothing Cross Entropy。
参数说明
- smooth_factor (Float,默认值为0) -如果正在使用LabelSmoothing,请改为0.1([0, 1])。
- num_classes (Float) - 用于onehot的class数量。
输出说明
Float - shape为(k, 5)和(k, 1)的张量。标签以0为基础。
支持的型号
- [object Object]Atlas 训练系列产品[object Object]
- [object Object]Atlas A2 训练系列产品[object Object]
- [object Object]Atlas A3 训练系列产品[object Object]
- [object Object]Atlas 推理系列产品[object Object]
调用示例
[object Object]