mindspore-ai / mindspore

MindSpore is a new open source deep learning training/inference framework that could be used for mobile, edge and cloud scenarios.
https://gitee.com/mindspore/mindspore
Apache License 2.0
4.31k stars 709 forks source link

Wrong parameter name in error message for BatchNorm1D #290

Open PhyllisJi opened 5 months ago

PhyllisJi commented 5 months ago

Software Environment:

Describe the current behavior

When the eps parameter is set to 0.0, mindspore throws an exception:

ValueError: For 'BatchNorm', the 'epsilon' must be in range of (0, 1], but got 0.0 with type 'float'.

Describe the expected behavior

ValueError: For 'BatchNorm', the 'eps' must be in range of (0, 1], but got 0.0 with type 'float'.

Steps to reproduce the issue

mindspore.nn.BatchNorm1d(num_features=512, eps=0.0, momentum=0.9, affine=True, use_batch_statistics=False)
WangruiMargaret commented 3 months ago

Thanks,we will correct the error message. https://gitee.com/mindspore/mindspore/pulls/72958