You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by zh...@apache.org on 2018/08/19 15:47:52 UTC

[incubator-mxnet] branch master updated: Don't override global warnings filter (#12245)

This is an automated email from the ASF dual-hosted git repository.

zhasheng pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-mxnet.git


The following commit(s) were added to refs/heads/master by this push:
     new 46437b8  Don't override global warnings filter (#12245)
46437b8 is described below

commit 46437b8102081ff3b18243494f5fc5e3aa4efed7
Author: Leonard Lausen <le...@lausen.nl>
AuthorDate: Sun Aug 19 23:47:42 2018 +0800

    Don't override global warnings filter (#12245)
    
    Currently import mxnet causes warnings.filterwarnings('default', category=DeprecationWarning) to be executed.
    This is very bad, as there are valid use cases where our users may have decided to filter out DeprecationWarning and we should not overwrite their configuration.
---
 python/mxnet/base.py | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/python/mxnet/base.py b/python/mxnet/base.py
index 3d8ee01..2bfcdd6 100644
--- a/python/mxnet/base.py
+++ b/python/mxnet/base.py
@@ -24,15 +24,12 @@ import atexit
 import ctypes
 import os
 import sys
-import warnings
 import inspect
 import platform
 import numpy as np
 
 from . import libinfo
 
-warnings.filterwarnings('default', category=DeprecationWarning)
-
 __all__ = ['MXNetError']
 #----------------------------
 # library loading