如何解决为什么在使用sklearn缩放数组期间出现数值问题警告?
我使用sklearn像这样缩放一个numpy数组:
from sklearn.preprocessing import scale
# Normalizing
if normalize:
for b in range(n_batches):
for i in range(n_samples):
for c in range(n_colors):
temp_interp[b,i,:,c] = scale(temp_interp[b,c])
我遇到此用户警告错误:
Numerical issues were encountered when scaling the data and might not be solved. The standard deviation of the data is probably very close to 0.
为什么会出现此错误?我怎样才能解决这个问题?当我使用带有此错误警告的缩放数据训练CNN时,有多重要?
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。