Commit f69b694c authored by Anthony Larcher's avatar Anthony Larcher
Browse files

refactoring

parent 69e3ae2e
......@@ -341,14 +341,14 @@ class TrainingMonitor():
self.is_best = True
# Initialize the logger
logging_format = '%(asctime)-15s-8s %(message)s'
logging_format = '%(asctime)-15s %(message)s'
logging.basicConfig(level=logging.DEBUG, format=logging_format, datefmt='%m-%d %H:%M')
self.logger = logging.getLogger('Monitoring')
self.logger.setLevel(logging.INFO)
logger = logging.getLogger('Monitoring')
logger.setLevel(logging.DEBUG)
# create file handler which logs even debug messages
fh = logging.FileHandler(output_file)
fh.setLevel(logging.INFO)
self.logger.addHandler(fh)
fh.setLevel(logging.DEBUG)
logger.addHandler(fh)
def display(self):
"""
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment