-
Notifications
You must be signed in to change notification settings - Fork 18.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
1 changed file
with
13 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,19 @@ | ||
# Suppress GLOG output for python bindings | ||
# unless explicitly requested in environment | ||
import os | ||
if 'GLOG_minloglevel' not in os.environ: | ||
# Hide INFO and WARNING, show ERROR and FATAL | ||
os.environ['GLOG_minloglevel'] = '2' | ||
_unset_glog_level = True | ||
else: | ||
_unset_glog_level = False | ||
|
||
from .pycaffe import Net, SGDSolver | ||
from ._caffe import set_mode_cpu, set_mode_gpu, set_device, Layer, get_solver | ||
from .proto.caffe_pb2 import TRAIN, TEST | ||
from .classifier import Classifier | ||
from .detector import Detector | ||
from . import io | ||
|
||
if _unset_glog_level: | ||
del os.environ['GLOG_minloglevel'] |