Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

configs.py 1.3 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
  1. __all__ = ['Configs']
  2. class Configs:
  3. def __init__(self):
  4. self.num_classes = 20 # Number of Classes (Default: PascalVOC2012 Dataset --> 20)
  5. self.cell_size = 7 # Paper Default: 7
  6. self.boxes_per_cell = 2 # Paper Default: 2
  7. self.input_width = 448 # Paper Default: 448
  8. self.input_height = 448 # Paper Default: 448
  9. self.eps = 1e-6
  10. # Loss coefficients (Lambda coefficients of paper)
  11. self.lambda_coord = 5 # Paper Default: 5
  12. self.lambda_noobj = 0.5 # Paper Default: 0.5
  13. # Custom lambda coefficients. (It is not mentioned in the paper)
  14. self.lambda_obj = 1 # Paper Default: 1
  15. self.lambda_class = 1 # Paper Default: 1
  16. # Train
  17. self.epochs = 105 # Paper Default: 135 (75 (lr: 1e-2) + 30 (lr: 1e-3) + 30 (lr: 1e-4))
  18. self.init_lr = 1e-4 # Paper Default: 1e-2
  19. self.lr_decay_rate = 0.5
  20. self.lr_decay_steps = 40000
  21. self.batch_size = 32
  22. self.val_step = 1
  23. self.tb_img_max_outputs = 6
  24. # Box postprocess parameters
  25. self.nms_iou_thr = 0.5
  26. self.conf_thr = 0.5 # Used visualization
  27. # Dataset sampling
  28. self.train_ds_sample_ratio = 1. # Use all training set
  29. self.val_ds_sample_ratio = 1. # Use all validation set
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...