You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

config.py 1.7 kB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. # Copyright 2020 Huawei Technologies Co., Ltd
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License");
  4. # you may not use this file except in compliance with the License.
  5. # You may obtain a copy of the License at
  6. #
  7. # http://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. # ===========================================================================
  15. """Network config setting, will be used in train.py and eval.py"""
  16. from easydict import EasyDict as ed
  17. config = ed({
  18. 'batch_size': 64,
  19. 'warmup_lr': 0.0004,
  20. 'lr_rates': [0.002, 0.004, 0.002, 0.0008, 0.0004, 0.0002, 0.00008, 0.00004, 0.000004],
  21. 'lr_steps': [1000, 10000, 40000, 60000, 80000, 100000, 130000, 160000, 190000],
  22. 'gamma': 0.5,
  23. 'weight_decay': 0.0005,
  24. 'momentum': 0.5,
  25. 'max_epoch': 2500,
  26. 'log_interval': 10,
  27. 'ckpt_path': '../../output',
  28. 'ckpt_interval': 1000,
  29. 'result_path': '../../results',
  30. 'input_shape': [768, 448],
  31. 'jitter': 0.3,
  32. 'flip': 0.5,
  33. 'hue': 0.1,
  34. 'sat': 1.5,
  35. 'val': 1.5,
  36. 'num_classes': 1,
  37. 'anchors': [
  38. [3, 4],
  39. [5, 6],
  40. [7, 9],
  41. [10, 13],
  42. [15, 19],
  43. [21, 26],
  44. [28, 36],
  45. [38, 49],
  46. [54, 71],
  47. [77, 102],
  48. [122, 162],
  49. [207, 268],
  50. ],
  51. 'anchors_mask': [(8, 9, 10, 11), (4, 5, 6, 7), (0, 1, 2, 3)],
  52. 'conf_thresh': 0.1,
  53. 'nms_thresh': 0.45,
  54. })