hello,
which is the best value to reduction instead of size_average=‘false’ to solve this error:
warnings.warn(warning.format(ret)) UserWarning: size_average and reduce args will be deprecated, please use reduction=‘mean’ instead
To me it is not an error. The solution is already shown in the warning message, which is to replace size_average='false' with reduction='none', if you wish to keep your input dimension:)
thank you for reply but in warning message said (reduction=‘mean’)not ‘none’ if I should track the warning,and when I put reduction=‘none’ H get this error
File “C:\Users\Admin\AppData\Local\Programs\Python\Python310\lib\site-packages\torch\autograd_init_.py”, line 67, in _make_grads
raise RuntimeError(“grad can be implicitly created only for scalar outputs”)
RuntimeError: grad can be implicitly created only for scalar outputs