Numpy / Polyfit - Suppress printing of Intel MKL Error message

本秂侑毒 提交于 2019-12-01 08:36:18
Jsl

If a function decides to print an error message directly to stdout/stderr without using the normal Python error reporting mechanism (i.e. exception handling and warnings), there's little you can do to stop it from doing so. If it really annoys you, you can apparently suppress writing to stderr altogether. There is a solution in another SO question as to how to do it temporarily (e.g. just for this function): Suppress stdout / stderr print from Python functions. Obviously if you do this, you're also going to miss all the relevant outputs from this function, too, so use it with caution.

The error

Intel MKL ERROR: Parameter 4 was incorrect on entry to DELSD

occurs when you have Nan or Inf value in your input. Please check and impute it.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!