Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

settings.py 1.1KB

12345678910111213141516171819202122232425262728293031323334
  1. #
  2. # Copyright 2019 The FATE Authors. All Rights Reserved.
  3. #
  4. # Licensed under the Apache License, Version 2.0 (the "License");
  5. # you may not use this file except in compliance with the License.
  6. # You may obtain a copy of the License at
  7. #
  8. # http://www.apache.org/licenses/LICENSE-2.0
  9. #
  10. # Unless required by applicable law or agreed to in writing, software
  11. # distributed under the License is distributed on an "AS IS" BASIS,
  12. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. # See the License for the specific language governing permissions and
  14. # limitations under the License.
  15. #
  16. # Logger
  17. import os
  18. from api.utils.file_utils import get_project_base_directory
  19. from api.utils.log_utils import LoggerFactory, getLogger
  20. DEBUG = 0
  21. LoggerFactory.set_directory(
  22. os.path.join(
  23. get_project_base_directory(),
  24. "logs",
  25. "flow"))
  26. # {CRITICAL: 50, FATAL:50, ERROR:40, WARNING:30, WARN:30, INFO:20, DEBUG:10, NOTSET:0}
  27. LoggerFactory.LEVEL = 30
  28. flow_logger = getLogger("flow")
  29. database_logger = getLogger("database")
  30. FLOAT_ZERO = 1e-8
  31. PARAM_MAXDEPTH = 5