【发布时间】:2014-07-14 22:20:27
【问题描述】:
我使用 theano 运行机器学习算法。我收到了很多关于 DeprecationWarning 的警告。来自 numpy 包。我想禁用此警告请建议选项。 警告性质:fromnumeric.py:932: DeprecationWarning: 将 ndim > 0 的数组转换为索引将导致将来出错
我尝试在运行配置后添加命令行选项 -W ignore 或 -W ignore::DeprecationWarning 但这些都不起作用
另外修复警告解决方案对我来说很好。看起来它已在 theano https://groups.google.com/forum/#!topic/theano-users/Hf7soRrnh8w 中修复,但我不知道在哪里可以找到这个更新版本的 theano
我正在使用 Anaconda 发行版 2.0.1 windows 8.1 - 64 位
谢谢
【问题讨论】:
-
在 StackOverflow 中查看 answer。在那篇文章中,您可以遵循其他建议,以防其中一个不起作用。
-
感谢 Carlos Cordoba,这些选项都不起作用,但是我发现了一些有用的东西,warnings.catch_warnings():warnings.simplefilter("ignore") main()
-
我真的很高兴你能弄明白! :)
标签: python python-2.7 spyder theano