Turn off INFO logging (again). (#3707)

Something must have started logging earlier than before, causing INFO-level logging to be initialized before we disabled it. This change disables INFO logging sooner.
This commit is contained in:
Skye Wanderman-Milne 2020-07-10 08:11:48 -07:00 committed by GitHub
parent 417de0d351
commit 44eae61059
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -12,6 +12,11 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# Set default logging level before any logging happens.
import os as _os
_os.environ.setdefault('TF_CPP_MIN_LOG_LEVEL', '1')
del _os
# flake8: noqa: F401
from .config import config
from .api import (
@ -85,9 +90,6 @@ from . import nn
from . import random
def _init():
import os
os.environ.setdefault('TF_CPP_MIN_LOG_LEVEL', '1')
from . import numpy # side-effecting import sets up operator overloads
_init()