diff --git a/.gitignore b/.gitignore index 3bb34f3..8a86b3d 100644 --- a/.gitignore +++ b/.gitignore @@ -19,7 +19,6 @@ *.MOV *.avi *.data -*.json *.cfg !cfg/yolov3*.cfg diff --git a/utils/logging.json b/utils/logging.json new file mode 100644 index 0000000..5ca2bcb --- /dev/null +++ b/utils/logging.json @@ -0,0 +1,46 @@ +{ + "version":1, + "disable_existing_loggers":false, + "formatters":{ + "simple":{ + "format":"%(asctime)s - %(module)s - %(thread)d - %(levelname)s : %(message)s" + } + }, + "handlers":{ + "console":{ + "class":"logging.StreamHandler", + "level":"DEBUG", + "formatter":"simple", + "stream":"ext://sys.stdout" + }, + "info_file_handler":{ + "class":"logging.handlers.RotatingFileHandler", + "level":"INFO", + "formatter":"simple", + "filename":"../log/ieemoo-ai-zhanting-biz.log", + "maxBytes":10485760, + "backupCount":20, + "encoding":"utf8" + }, + "error_file_handler":{ + "class":"logging.handlers.RotatingFileHandler", + "level":"ERROR", + "formatter":"simple", + "filename":"../log/ieemoo-ai-zhanting-biz.log", + "maxBytes":10485760, + "backupCount":20, + "encoding":"utf8" + } + }, + "loggers":{ + "my_module":{ + "level":"ERROR", + "handlers":["info_file_handler"], + "propagate":"no"} + }, + "root":{ + "level":"INFO", + "handlers":["console","info_file_handler","error_file_handler"] + } +} +