Improving transfer learning training of object detection model

username: Santhoshnumberone
cooked: <h2>
<a name="i-am-using-a-pre-trained-pytorch-object-detection-model-for-transfer-learning-on-custom-data-i-want-to-train-1" class="anchor" href="#i-am-using-a-pre-trained-pytorch-object-detection-model-for-transfer-learning-on-custom-data-i-want-to-train-1"></a>I am using a pre trained pytorch object detection model for transfer learning on custom data I want to train.</h2>
<p>I am referring to <a href="https://towardsdatascience.com/building-your-own-object-detector-pytorch-vs-tensorflow-and-how-to-even-get-started-1d314691d4ae#fdfa" rel="noopener nofollow ugc">Building your own object detector — PyTorch vs TensorFlow and how to even get started?</a></p>
<p>My custom data I want to train is being detected as label <code>77</code>-<code>Cell Phone</code> when inferred on <code>fasterrcnn_resnet50_fpn</code>, so I replaced the final classification layers <code>weight</code> &amp; <code>bias</code> with only <code>0</code> label <code>background</code> and <code>77</code> label <code>Cell Phone</code></p>
<p>I started with training</p>
<h2>
<a name="first-i-used-adam-with-lambdlr-2" class="anchor" href="#first-i-used-adam-with-lambdlr-2"></a><strong>First I used <code>Adam</code> with <code>LambdLR</code></strong>
</h2>
<p><strong>Optimizer</strong></p>
<pre><code class="lang-auto">optimizer = torch.optim.Adam(params,lr=0.005,betas=(0.9,0.999),eps=1e-08,weight_decay=0.0005,amsgrad=False)
</code></pre>
<p><strong>Learning rate</strong></p>
<pre><code class="lang-auto">lambda1 = lambda epoch: 0.65 ** epoch
lr_scheduler = torch.optim.lr_scheduler.LambdaLR(optimizer, lr_lambda=lambda1)
</code></pre>
<p>This is it’s training output</p>
<pre><code class="lang-auto">Epoch: [0]  [188/189]  eta: 0:00:05  lr: 0.005000  loss: 0.1684 (0.1853)  loss_classifier: 0.0370 (0.0534)  loss_box_reg: 0.1215 (0.1199)  loss_objectness: 0.0060 (0.0063)  loss_rpn_box_reg: 0.0054 (0.0056)  time: 5.4183  data: 0.0438  max mem: 8036
Epoch: [0] Total time: 0:16:33 (5.2578 s / it)
Test: Total time: 0:02:22 (0.3780 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.062
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.166
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.039
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.063
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.104
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.329
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.329
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.329

Epoch: [1]  [188/189]  eta: 0:00:05  lr: 0.003250  loss: 0.1665 (0.1679)  loss_classifier: 0.0327 (0.0352)  loss_box_reg: 0.1244 (0.1207)  loss_objectness: 0.0067 (0.0065)  loss_rpn_box_reg: 0.0047 (0.0056)  time: 4.8139  data: 0.0454  max mem: 8036
Epoch: [1] Total time: 0:16:07 (5.1194 s / it)
Test: Total time: 0:02:23 (0.3783 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.058
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.161
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.060
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.100
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.337
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.337
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.337

 Epoch: [2]  [188/189]  eta: 0:00:05  lr: 0.002113  loss: 0.1724 (0.1649)  loss_classifier: 0.0333 (0.0328)  loss_box_reg: 0.1212 (0.1199)  loss_objectness: 0.0065 (0.0066)  loss_rpn_box_reg: 0.0054 (0.0055)  time: 4.6630  data: 0.0454  max mem: 8036
Epoch: [2] Total time: 0:16:22 (5.1970 s / it)
Test: Total time: 0:02:22 (0.3779 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.063
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.171
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.038
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.064
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.104
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.348
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.348
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.348

 Epoch: [3]  [188/189]  eta: 0:00:05  lr: 0.001373  loss: 0.1601 (0.1640)  loss_classifier: 0.0314 (0.0322)  loss_box_reg: 0.1156 (0.1199)  loss_objectness: 0.0052 (0.0062)  loss_rpn_box_reg: 0.0052 (0.0056)  time: 5.1234  data: 0.0467  max mem: 8036
Epoch: [3] Total time: 0:16:28 (5.2321 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.166
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.035
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.101
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.346
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.346
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.346

 Epoch: [4]  [188/189]  eta: 0:00:05  lr: 0.000893  loss: 0.1527 (0.1635)  loss_classifier: 0.0286 (0.0314)  loss_box_reg: 0.1091 (0.1204)  loss_objectness: 0.0054 (0.0062)  loss_rpn_box_reg: 0.0051 (0.0056)  time: 5.1214  data: 0.0482  max mem: 8036
Epoch: [4] Total time: 0:16:28 (5.2280 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.035
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.102
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.346
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.346
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.346

 Epoch: [5]  [188/189]  eta: 0:00:05  lr: 0.000580  loss: 0.1585 (0.1635)  loss_classifier: 0.0271 (0.0312)  loss_box_reg: 0.1103 (0.1200)  loss_objectness: 0.0061 (0.0067)  loss_rpn_box_reg: 0.0059 (0.0055)  time: 5.1237  data: 0.0476  max mem: 8036
Epoch: [5] Total time: 0:16:23 (5.2050 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.169
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.035
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.102
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.349
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.349
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.349

 Epoch: [6]  [188/189]  eta: 0:00:05  lr: 0.000377  loss: 0.1621 (0.1628)  loss_classifier: 0.0308 (0.0311)  loss_box_reg: 0.1170 (0.1197)  loss_objectness: 0.0061 (0.0065)  loss_rpn_box_reg: 0.0052 (0.0055)  time: 5.2761  data: 0.0485  max mem: 8036
Epoch: [6] Total time: 0:16:32 (5.2489 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.035
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.102
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.352
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.352
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.352

 Epoch: [7]  [188/189]  eta: 0:00:05  lr: 0.000245  loss: 0.1600 (0.1630)  loss_classifier: 0.0294 (0.0309)  loss_box_reg: 0.1154 (0.1201)  loss_objectness: 0.0064 (0.0064)  loss_rpn_box_reg: 0.0050 (0.0056)  time: 5.5080  data: 0.0453  max mem: 8036
Epoch: [7] Total time: 0:16:51 (5.3507 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.063
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.102
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.349
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.349
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.349

 Epoch: [8]  [188/189]  eta: 0:00:05  lr: 0.000159  loss: 0.1602 (0.1624)  loss_classifier: 0.0283 (0.0308)  loss_box_reg: 0.1206 (0.1198)  loss_objectness: 0.0051 (0.0062)  loss_rpn_box_reg: 0.0047 (0.0056)  time: 5.4158  data: 0.0434  max mem: 8036
Epoch: [8] Total time: 0:16:42 (5.3026 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.169
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.035
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.063
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.102
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.350
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.350
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.350

 Epoch: [9]  [188/189]  eta: 0:00:05  lr: 0.000104  loss: 0.1595 (0.1623)  loss_classifier: 0.0278 (0.0308)  loss_box_reg: 0.1183 (0.1195)  loss_objectness: 0.0053 (0.0064)  loss_rpn_box_reg: 0.0051 (0.0056)  time: 4.9586  data: 0.0437  max mem: 8036
Epoch: [9] Total time: 0:16:14 (5.1535 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.062
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.035
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.063
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.102
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.351
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.351
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.351
</code></pre>
<h4>
<a name="i-dont-know-why-i-get-1-values-what-does-1-mean-3" class="anchor" href="#i-dont-know-why-i-get-1-values-what-does-1-mean-3"></a>I don’t know why I get <strong>-1</strong> values, what does <strong>-1</strong> mean?</h4>
<h4>
<a name="can-anyone-guide-me-as-to-how-to-improve-training-after-looking-at-these-results-4" class="anchor" href="#can-anyone-guide-me-as-to-how-to-improve-training-after-looking-at-these-results-4"></a>Can anyone guide me as to how to improve training after looking at these results</h4>
<h4>
<a name="i-feel-i-need-to-used-steplr-instead-of-lambdlr-to-bring-down-losses-an-improve-accuracy-5" class="anchor" href="#i-feel-i-need-to-used-steplr-instead-of-lambdlr-to-bring-down-losses-an-improve-accuracy-5"></a>I feel I need to used <code>stepLR</code> instead of <code>LambdLR</code> to bring down losses an improve accuracy</h4>
<h2>
<a name="second-i-used-sgd-with-steplr-6" class="anchor" href="#second-i-used-sgd-with-steplr-6"></a><strong>Second I used <code>SGD</code> with <code>StepLR</code></strong>
</h2>
<p><strong>Optimizer</strong></p>
<pre><code class="lang-auto">optimizer = torch.optim.SGD(params, lr=0.005,momentum=0.9, weight_decay=0.0005)
</code></pre>
<p><strong>Learning Rate</strong></p>
<pre><code class="lang-auto">lr_scheduler = torch.optim.lr_scheduler.StepLR(optimizer,step_size=3,gamma=0.1)
</code></pre>
<p>This is it’s training output</p>
<pre><code class="lang-auto">Epoch: [0]  [188/189]  eta: 0:00:01  lr: 0.005000  loss: 0.1822 (0.2051)  loss_classifier: 0.0509 (0.0732)  loss_box_reg: 0.1215 (0.1199)  loss_objectness: 0.0063 (0.0064)  loss_rpn_box_reg: 0.0054 (0.0056)  time: 1.7622  data: 0.0290  max mem: 10953
Epoch: [0] Total time: 0:05:29 (1.7410 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.062
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.171
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.063
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.098
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.342
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.342
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.

 Epoch: [1]  [188/189]  eta: 0:00:01  lr: 0.005000  loss: 0.1809 (0.1800)  loss_classifier: 0.0421 (0.0472)  loss_box_reg: 0.1244 (0.1207)  loss_objectness: 0.0066 (0.0066)  loss_rpn_box_reg: 0.0047 (0.0056)  time: 1.6265  data: 0.0287  max mem: 10953
Epoch: [1] Total time: 0:05:21 (1.7014 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.062
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.168
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.063
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.103
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.346
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.346
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.346


 Epoch: [2]  [188/189]  eta: 0:00:01  lr: 0.005000  loss: 0.1827 (0.1752)  loss_classifier: 0.0415 (0.0432)  loss_box_reg: 0.1212 (0.1199)  loss_objectness: 0.0079 (0.0066)  loss_rpn_box_reg: 0.0054 (0.0055)  time: 1.5905  data: 0.0288  max mem: 10953
Epoch: [2] Total time: 0:05:24 (1.7192 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.167
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.105
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343

 Epoch: [3]  [188/189]  eta: 0:00:01  lr: 0.000500  loss: 0.1736 (0.1735)  loss_classifier: 0.0423 (0.0418)  loss_box_reg: 0.1156 (0.1199)  loss_objectness: 0.0053 (0.0062)  loss_rpn_box_reg: 0.0052 (0.0056)  time: 1.6961  data: 0.0297  max mem: 10953
Epoch: [3] Total time: 0:05:26 (1.7274 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.167
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.034
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.105
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343

 Epoch: [4]  [188/189]  eta: 0:00:01  lr: 0.000500  loss: 0.1579 (0.1737)  loss_classifier: 0.0364 (0.0414)  loss_box_reg: 0.1091 (0.1204)  loss_objectness: 0.0052 (0.0064)  loss_rpn_box_reg: 0.0051 (0.0056)  time: 1.6901  data: 0.0277  max mem: 10953
Epoch: [4] Total time: 0:05:26 (1.7270 s / it)


IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.172
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.106
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.344
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.344
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.344

 Epoch: [5]  [188/189]  eta: 0:00:01  lr: 0.000500  loss: 0.1687 (0.1740)  loss_classifier: 0.0368 (0.0419)  loss_box_reg: 0.1103 (0.1200)  loss_objectness: 0.0048 (0.0065)  loss_rpn_box_reg: 0.0059 (0.0055)  time: 1.6966  data: 0.0297  max mem: 10953
Epoch: [5] Total time: 0:05:25 (1.7211 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.106
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343

 Epoch: [6]  [188/189]  eta: 0:00:01  lr: 0.000050  loss: 0.1714 (0.1729)  loss_classifier: 0.0423 (0.0415)  loss_box_reg: 0.1170 (0.1197)  loss_objectness: 0.0046 (0.0062)  loss_rpn_box_reg: 0.0052 (0.0055)  time: 1.7284  data: 0.0293  max mem: 10953
Epoch: [6] Total time: 0:05:26 (1.7288 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.106
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343

 Epoch: [7]  [188/189]  eta: 0:00:01  lr: 0.000050  loss: 0.1639 (0.1735)  loss_classifier: 0.0378 (0.0415)  loss_box_reg: 0.1154 (0.1201)  loss_objectness: 0.0048 (0.0063)  loss_rpn_box_reg: 0.0050 (0.0056)  time: 1.7644  data: 0.0288  max mem: 10953
Epoch: [7] Total time: 0:05:30 (1.7465 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.106
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343

 Epoch: [8]  [188/189]  eta: 0:00:01  lr: 0.000050  loss: 0.1732 (0.1731)  loss_classifier: 0.0375 (0.0414)  loss_box_reg: 0.1206 (0.1198)  loss_objectness: 0.0055 (0.0063)  loss_rpn_box_reg: 0.0047 (0.0056)  time: 1.7641  data: 0.0280  max mem: 10953
Epoch: [8] Total time: 0:05:29 (1.7419 s / it)


IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.106
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343

 Epoch: [9]  [188/189]  eta: 0:00:01  lr: 0.000005  loss: 0.1699 (0.1729)  loss_classifier: 0.0380 (0.0414)  loss_box_reg: 0.1183 (0.1195)  loss_objectness: 0.0057 (0.0065)  loss_rpn_box_reg: 0.0051 (0.0056)  time: 1.6622  data: 0.0298  max mem: 10953
Epoch: [9] Total time: 0:05:23 (1.7121 s / it)

IoU metric: bbox
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.061
 Average Precision  (AP) @[ IoU=0.50      | area=   all | maxDets=100 ] = 0.170
 Average Precision  (AP) @[ IoU=0.75      | area=   all | maxDets=100 ] = 0.033
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Precision  (AP) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.062
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=  1 ] = 0.106
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets= 10 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=   all | maxDets=100 ] = 0.343
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= small | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area=medium | maxDets=100 ] = -1.000
 Average Recall     (AR) @[ IoU=0.50:0.95 | area= large | maxDets=100 ] = 0.343
</code></pre>
<h4>
<a name="i-feel-adam-is-better-both-in-terms-of-reducing-losses-and-improving-ap-and-ar-of-iou-metric-7" class="anchor" href="#i-feel-adam-is-better-both-in-terms-of-reducing-losses-and-improving-ap-and-ar-of-iou-metric-7"></a>I feel Adam is better both in terms of reducing <code>losses</code> and improving <code>AP</code> and <code>AR</code> of IoU Metric</h4>