ShinyaJ commited on
Commit
a2bd77a
·
verified ·
1 Parent(s): b7918b2

Upload 2 files

Browse files
co_dino_5scale_swin_l_16xb1_1x_coco.py ADDED
@@ -0,0 +1,862 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ auto_scale_lr = dict(base_batch_size=16)
2
+ backend_args = None
3
+ batch_augments = [
4
+ dict(size=(
5
+ 1024,
6
+ 1024,
7
+ ), type='BatchFixedSizePad'),
8
+ ]
9
+ classes = 'license_plate'
10
+ custom_imports = dict(
11
+ allow_failed_imports=False, imports=[
12
+ 'projects.CO-DETR.codetr',
13
+ ])
14
+ data_root = '/home/worawit.tepsan/Project_AI/Detection/data'
15
+ dataset_type = 'CocoDataset'
16
+ default_hooks = dict(
17
+ checkpoint=dict(
18
+ _scope_='mmdet',
19
+ by_epoch=True,
20
+ interval=1,
21
+ max_keep_ckpts=3,
22
+ type='CheckpointHook'),
23
+ logger=dict(_scope_='mmdet', interval=50, type='LoggerHook'),
24
+ param_scheduler=dict(_scope_='mmdet', type='ParamSchedulerHook'),
25
+ sampler_seed=dict(_scope_='mmdet', type='DistSamplerSeedHook'),
26
+ timer=dict(_scope_='mmdet', type='IterTimerHook'),
27
+ visualization=dict(
28
+ _scope_='mmdet',
29
+ draw=True,
30
+ test_out_dir=
31
+ '/home/worawit.tepsan/Project_AI/Detection/data_testing_LPR',
32
+ type='DetVisualizationHook'))
33
+ default_scope = 'mmdet'
34
+ env_cfg = dict(
35
+ cudnn_benchmark=False,
36
+ dist_cfg=dict(backend='nccl'),
37
+ mp_cfg=dict(mp_start_method='fork', opencv_num_threads=0))
38
+ image_size = (
39
+ 1024,
40
+ 1024,
41
+ )
42
+ launcher = 'slurm'
43
+ load_from = '/home/worawit.tepsan/Project_AI/Detection/object_detection/workdir/epoch_13.pth'
44
+ load_pipeline = [
45
+ dict(type='LoadImageFromFile'),
46
+ dict(type='LoadAnnotations', with_bbox=True),
47
+ dict(
48
+ keep_ratio=True,
49
+ ratio_range=(
50
+ 0.1,
51
+ 2.0,
52
+ ),
53
+ scale=(
54
+ 1024,
55
+ 1024,
56
+ ),
57
+ type='RandomResize'),
58
+ dict(
59
+ allow_negative_crop=True,
60
+ crop_size=(
61
+ 1024,
62
+ 1024,
63
+ ),
64
+ crop_type='absolute_range',
65
+ recompute_bbox=True,
66
+ type='RandomCrop'),
67
+ dict(min_gt_bbox_wh=(
68
+ 0.01,
69
+ 0.01,
70
+ ), type='FilterAnnotations'),
71
+ dict(prob=0.5, type='RandomFlip'),
72
+ dict(pad_val=dict(img=(
73
+ 114,
74
+ 114,
75
+ 114,
76
+ )), size=(
77
+ 1024,
78
+ 1024,
79
+ ), type='Pad'),
80
+ ]
81
+ log_level = 'INFO'
82
+ log_processor = dict(
83
+ _scope_='mmdet', by_epoch=True, type='LogProcessor', window_size=50)
84
+ loss_lambda = 2.0
85
+ max_epochs = 32
86
+ max_iters = 270000
87
+ metainfo = dict(classes='license_plate')
88
+ model = dict(
89
+ backbone=dict(
90
+ attn_drop_rate=0.0,
91
+ convert_weights=True,
92
+ depths=[
93
+ 2,
94
+ 2,
95
+ 18,
96
+ 2,
97
+ ],
98
+ drop_path_rate=0.3,
99
+ drop_rate=0.0,
100
+ embed_dims=192,
101
+ init_cfg=dict(
102
+ checkpoint=
103
+ '/home/worawit.tepsan/Project_AI/Detection/pretrained_models/swin_large_patch4_window12_384_22k.pth',
104
+ type='Pretrained'),
105
+ mlp_ratio=4,
106
+ num_heads=[
107
+ 6,
108
+ 12,
109
+ 24,
110
+ 48,
111
+ ],
112
+ out_indices=(
113
+ 0,
114
+ 1,
115
+ 2,
116
+ 3,
117
+ ),
118
+ patch_norm=True,
119
+ pretrain_img_size=384,
120
+ qk_scale=None,
121
+ qkv_bias=True,
122
+ type='SwinTransformer',
123
+ window_size=12,
124
+ with_cp=False),
125
+ bbox_head=[
126
+ dict(
127
+ anchor_generator=dict(
128
+ octave_base_scale=8,
129
+ ratios=[
130
+ 1.0,
131
+ ],
132
+ scales_per_octave=1,
133
+ strides=[
134
+ 4,
135
+ 8,
136
+ 16,
137
+ 32,
138
+ 64,
139
+ 128,
140
+ ],
141
+ type='AnchorGenerator'),
142
+ bbox_coder=dict(
143
+ target_means=[
144
+ 0.0,
145
+ 0.0,
146
+ 0.0,
147
+ 0.0,
148
+ ],
149
+ target_stds=[
150
+ 0.1,
151
+ 0.1,
152
+ 0.2,
153
+ 0.2,
154
+ ],
155
+ type='DeltaXYWHBBoxCoder'),
156
+ feat_channels=256,
157
+ in_channels=256,
158
+ loss_bbox=dict(loss_weight=24.0, type='GIoULoss'),
159
+ loss_centerness=dict(
160
+ loss_weight=12.0, type='CrossEntropyLoss', use_sigmoid=True),
161
+ loss_cls=dict(
162
+ alpha=0.25,
163
+ gamma=2.0,
164
+ loss_weight=12.0,
165
+ type='FocalLoss',
166
+ use_sigmoid=True),
167
+ num_classes=1,
168
+ stacked_convs=1,
169
+ type='CoATSSHead'),
170
+ ],
171
+ data_preprocessor=dict(
172
+ batch_augments=None,
173
+ bgr_to_rgb=True,
174
+ mean=[
175
+ 123.675,
176
+ 116.28,
177
+ 103.53,
178
+ ],
179
+ pad_mask=False,
180
+ std=[
181
+ 58.395,
182
+ 57.12,
183
+ 57.375,
184
+ ],
185
+ type='DetDataPreprocessor'),
186
+ eval_module='detr',
187
+ neck=dict(
188
+ act_cfg=None,
189
+ in_channels=[
190
+ 192,
191
+ 384,
192
+ 768,
193
+ 1536,
194
+ ],
195
+ kernel_size=1,
196
+ norm_cfg=dict(num_groups=32, type='GN'),
197
+ num_outs=5,
198
+ out_channels=256,
199
+ type='ChannelMapper'),
200
+ query_head=dict(
201
+ as_two_stage=True,
202
+ dn_cfg=dict(
203
+ box_noise_scale=1.0,
204
+ group_cfg=dict(dynamic=True, num_dn_queries=100, num_groups=None),
205
+ label_noise_scale=0.5),
206
+ in_channels=2048,
207
+ loss_bbox=dict(loss_weight=5.0, type='L1Loss'),
208
+ loss_cls=dict(
209
+ beta=2.0,
210
+ loss_weight=1.0,
211
+ type='QualityFocalLoss',
212
+ use_sigmoid=True),
213
+ loss_iou=dict(loss_weight=2.0, type='GIoULoss'),
214
+ num_classes=1,
215
+ num_query=900,
216
+ positional_encoding=dict(
217
+ normalize=True,
218
+ num_feats=128,
219
+ temperature=20,
220
+ type='SinePositionalEncoding'),
221
+ transformer=dict(
222
+ decoder=dict(
223
+ num_layers=6,
224
+ return_intermediate=True,
225
+ transformerlayers=dict(
226
+ attn_cfgs=[
227
+ dict(
228
+ dropout=0.0,
229
+ embed_dims=256,
230
+ num_heads=8,
231
+ type='MultiheadAttention'),
232
+ dict(
233
+ dropout=0.0,
234
+ embed_dims=256,
235
+ num_levels=5,
236
+ type='MultiScaleDeformableAttention'),
237
+ ],
238
+ feedforward_channels=2048,
239
+ ffn_dropout=0.0,
240
+ operation_order=(
241
+ 'self_attn',
242
+ 'norm',
243
+ 'cross_attn',
244
+ 'norm',
245
+ 'ffn',
246
+ 'norm',
247
+ ),
248
+ type='DetrTransformerDecoderLayer'),
249
+ type='DinoTransformerDecoder'),
250
+ encoder=dict(
251
+ num_layers=6,
252
+ transformerlayers=dict(
253
+ attn_cfgs=dict(
254
+ dropout=0.0,
255
+ embed_dims=256,
256
+ num_levels=5,
257
+ type='MultiScaleDeformableAttention'),
258
+ feedforward_channels=2048,
259
+ ffn_dropout=0.0,
260
+ operation_order=(
261
+ 'self_attn',
262
+ 'norm',
263
+ 'ffn',
264
+ 'norm',
265
+ ),
266
+ type='BaseTransformerLayer'),
267
+ type='DetrTransformerEncoder',
268
+ with_cp=6),
269
+ num_co_heads=2,
270
+ num_feature_levels=5,
271
+ type='CoDinoTransformer',
272
+ with_coord_feat=False),
273
+ type='CoDINOHead'),
274
+ roi_head=[
275
+ dict(
276
+ bbox_head=dict(
277
+ bbox_coder=dict(
278
+ target_means=[
279
+ 0.0,
280
+ 0.0,
281
+ 0.0,
282
+ 0.0,
283
+ ],
284
+ target_stds=[
285
+ 0.1,
286
+ 0.1,
287
+ 0.2,
288
+ 0.2,
289
+ ],
290
+ type='DeltaXYWHBBoxCoder'),
291
+ fc_out_channels=1024,
292
+ in_channels=256,
293
+ loss_bbox=dict(loss_weight=120.0, type='GIoULoss'),
294
+ loss_cls=dict(
295
+ loss_weight=12.0,
296
+ type='CrossEntropyLoss',
297
+ use_sigmoid=False),
298
+ num_classes=1,
299
+ reg_class_agnostic=False,
300
+ reg_decoded_bbox=True,
301
+ roi_feat_size=7,
302
+ type='Shared2FCBBoxHead'),
303
+ bbox_roi_extractor=dict(
304
+ featmap_strides=[
305
+ 4,
306
+ 8,
307
+ 16,
308
+ 32,
309
+ 64,
310
+ ],
311
+ finest_scale=56,
312
+ out_channels=256,
313
+ roi_layer=dict(
314
+ output_size=7, sampling_ratio=0, type='RoIAlign'),
315
+ type='SingleRoIExtractor'),
316
+ type='CoStandardRoIHead'),
317
+ ],
318
+ rpn_head=dict(
319
+ anchor_generator=dict(
320
+ octave_base_scale=4,
321
+ ratios=[
322
+ 0.5,
323
+ 1.0,
324
+ 2.0,
325
+ ],
326
+ scales_per_octave=3,
327
+ strides=[
328
+ 4,
329
+ 8,
330
+ 16,
331
+ 32,
332
+ 64,
333
+ 128,
334
+ ],
335
+ type='AnchorGenerator'),
336
+ bbox_coder=dict(
337
+ target_means=[
338
+ 0.0,
339
+ 0.0,
340
+ 0.0,
341
+ 0.0,
342
+ ],
343
+ target_stds=[
344
+ 1.0,
345
+ 1.0,
346
+ 1.0,
347
+ 1.0,
348
+ ],
349
+ type='DeltaXYWHBBoxCoder'),
350
+ feat_channels=256,
351
+ in_channels=256,
352
+ loss_bbox=dict(loss_weight=12.0, type='L1Loss'),
353
+ loss_cls=dict(
354
+ loss_weight=12.0, type='CrossEntropyLoss', use_sigmoid=True),
355
+ type='RPNHead'),
356
+ test_cfg=[
357
+ dict(max_per_img=300, nms=dict(iou_threshold=0.8, type='soft_nms')),
358
+ dict(
359
+ rcnn=dict(
360
+ max_per_img=100,
361
+ nms=dict(iou_threshold=0.5, type='nms'),
362
+ score_thr=0.0),
363
+ rpn=dict(
364
+ max_per_img=1000,
365
+ min_bbox_size=0,
366
+ nms=dict(iou_threshold=0.7, type='nms'),
367
+ nms_pre=1000)),
368
+ dict(
369
+ max_per_img=100,
370
+ min_bbox_size=0,
371
+ nms=dict(iou_threshold=0.6, type='nms'),
372
+ nms_pre=1000,
373
+ score_thr=0.0),
374
+ ],
375
+ train_cfg=[
376
+ dict(
377
+ assigner=dict(
378
+ match_costs=[
379
+ dict(type='FocalLossCost', weight=2.0),
380
+ dict(box_format='xywh', type='BBoxL1Cost', weight=5.0),
381
+ dict(iou_mode='giou', type='IoUCost', weight=2.0),
382
+ ],
383
+ type='HungarianAssigner')),
384
+ dict(
385
+ rcnn=dict(
386
+ assigner=dict(
387
+ ignore_iof_thr=-1,
388
+ match_low_quality=False,
389
+ min_pos_iou=0.5,
390
+ neg_iou_thr=0.5,
391
+ pos_iou_thr=0.5,
392
+ type='MaxIoUAssigner'),
393
+ debug=False,
394
+ pos_weight=-1,
395
+ sampler=dict(
396
+ add_gt_as_proposals=True,
397
+ neg_pos_ub=-1,
398
+ num=512,
399
+ pos_fraction=0.25,
400
+ type='RandomSampler')),
401
+ rpn=dict(
402
+ allowed_border=-1,
403
+ assigner=dict(
404
+ ignore_iof_thr=-1,
405
+ match_low_quality=True,
406
+ min_pos_iou=0.3,
407
+ neg_iou_thr=0.3,
408
+ pos_iou_thr=0.7,
409
+ type='MaxIoUAssigner'),
410
+ debug=False,
411
+ pos_weight=-1,
412
+ sampler=dict(
413
+ add_gt_as_proposals=False,
414
+ neg_pos_ub=-1,
415
+ num=256,
416
+ pos_fraction=0.5,
417
+ type='RandomSampler')),
418
+ rpn_proposal=dict(
419
+ max_per_img=1000,
420
+ min_bbox_size=0,
421
+ nms=dict(iou_threshold=0.7, type='nms'),
422
+ nms_pre=4000)),
423
+ dict(
424
+ allowed_border=-1,
425
+ assigner=dict(topk=9, type='ATSSAssigner'),
426
+ debug=False,
427
+ pos_weight=-1),
428
+ ],
429
+ type='CoDETR',
430
+ use_lsj=False)
431
+ num_classes = 1
432
+ num_dec_layer = 6
433
+ optim_wrapper = dict(
434
+ clip_grad=dict(max_norm=0.1, norm_type=2),
435
+ optimizer=dict(lr=0.0002, type='AdamW', weight_decay=0.0001),
436
+ paramwise_cfg=dict(custom_keys=dict(backbone=dict(lr_mult=0.1))),
437
+ type='OptimWrapper')
438
+ param_scheduler = [
439
+ dict(
440
+ begin=0,
441
+ by_epoch=True,
442
+ end=12,
443
+ gamma=0.1,
444
+ milestones=[
445
+ 11,
446
+ ],
447
+ type='MultiStepLR'),
448
+ ]
449
+ pretrained = '/home/worawit.tepsan/Project_AI/Detection/pretrained_models/swin_large_patch4_window12_384_22k.pth'
450
+ resume = False
451
+ test_cfg = dict(_scope_='mmdet', type='TestLoop')
452
+ test_dataloader = dict(
453
+ batch_size=2,
454
+ dataset=dict(
455
+ _scope_='mmdet',
456
+ ann_file='annotations/instances_test.json',
457
+ data_prefix=dict(img='test/'),
458
+ data_root='/home/worawit.tepsan/Project_AI/Detection/data',
459
+ metainfo=dict(classes='license_plate'),
460
+ pipeline=[
461
+ dict(backend_args=None, type='LoadImageFromFile'),
462
+ dict(keep_ratio=True, scale=(
463
+ 1333,
464
+ 800,
465
+ ), type='Resize'),
466
+ dict(
467
+ meta_keys=(
468
+ 'img_id',
469
+ 'img_path',
470
+ 'ori_shape',
471
+ 'img_shape',
472
+ 'scale_factor',
473
+ ),
474
+ type='PackDetInputs'),
475
+ ],
476
+ test_mode=True,
477
+ type='CocoDataset'),
478
+ drop_last=False,
479
+ num_workers=8,
480
+ persistent_workers=True,
481
+ sampler=dict(_scope_='mmdet', shuffle=False, type='DefaultSampler'))
482
+ test_evaluator = dict(
483
+ _scope_='mmdet',
484
+ ann_file='annotations/instances_test.json',
485
+ format_only=False,
486
+ metric='bbox',
487
+ outfile_prefix=
488
+ '/home/worawit.tepsan/Project_AI/Detection/object_detection/workdir/coco_detection/test',
489
+ type='CocoMetric')
490
+ test_pipeline = [
491
+ dict(backend_args=None, type='LoadImageFromFile'),
492
+ dict(keep_ratio=True, scale=(
493
+ 1333,
494
+ 800,
495
+ ), type='Resize'),
496
+ dict(
497
+ meta_keys=(
498
+ 'img_id',
499
+ 'img_path',
500
+ 'ori_shape',
501
+ 'img_shape',
502
+ 'scale_factor',
503
+ ),
504
+ type='PackDetInputs'),
505
+ ]
506
+ train_cfg = dict(max_epochs=32, type='EpochBasedTrainLoop', val_interval=1)
507
+ train_dataloader = dict(
508
+ batch_size=2,
509
+ dataset=dict(
510
+ ann_file='annotations/instances_train.json',
511
+ backend_args=None,
512
+ data_prefix=dict(img='train/'),
513
+ data_root='/home/worawit.tepsan/Project_AI/Detection/data',
514
+ filter_cfg=dict(filter_empty_gt=False, min_size=32),
515
+ metainfo=dict(classes='license_plate'),
516
+ pipeline=[
517
+ dict(backend_args=None, type='LoadImageFromFile'),
518
+ dict(type='LoadAnnotations', with_bbox=True),
519
+ dict(prob=0.5, type='RandomFlip'),
520
+ dict(
521
+ transforms=[
522
+ [
523
+ dict(
524
+ keep_ratio=True,
525
+ scales=[
526
+ (
527
+ 480,
528
+ 1333,
529
+ ),
530
+ (
531
+ 512,
532
+ 1333,
533
+ ),
534
+ (
535
+ 544,
536
+ 1333,
537
+ ),
538
+ (
539
+ 576,
540
+ 1333,
541
+ ),
542
+ (
543
+ 608,
544
+ 1333,
545
+ ),
546
+ (
547
+ 640,
548
+ 1333,
549
+ ),
550
+ (
551
+ 672,
552
+ 1333,
553
+ ),
554
+ (
555
+ 704,
556
+ 1333,
557
+ ),
558
+ (
559
+ 736,
560
+ 1333,
561
+ ),
562
+ (
563
+ 768,
564
+ 1333,
565
+ ),
566
+ (
567
+ 800,
568
+ 1333,
569
+ ),
570
+ ],
571
+ type='RandomChoiceResize'),
572
+ ],
573
+ [
574
+ dict(
575
+ keep_ratio=True,
576
+ scales=[
577
+ (
578
+ 400,
579
+ 4200,
580
+ ),
581
+ (
582
+ 500,
583
+ 4200,
584
+ ),
585
+ (
586
+ 600,
587
+ 4200,
588
+ ),
589
+ ],
590
+ type='RandomChoiceResize'),
591
+ dict(
592
+ allow_negative_crop=True,
593
+ crop_size=(
594
+ 384,
595
+ 600,
596
+ ),
597
+ crop_type='absolute_range',
598
+ type='RandomCrop'),
599
+ dict(
600
+ keep_ratio=True,
601
+ scales=[
602
+ (
603
+ 480,
604
+ 1333,
605
+ ),
606
+ (
607
+ 512,
608
+ 1333,
609
+ ),
610
+ (
611
+ 544,
612
+ 1333,
613
+ ),
614
+ (
615
+ 576,
616
+ 1333,
617
+ ),
618
+ (
619
+ 608,
620
+ 1333,
621
+ ),
622
+ (
623
+ 640,
624
+ 1333,
625
+ ),
626
+ (
627
+ 672,
628
+ 1333,
629
+ ),
630
+ (
631
+ 704,
632
+ 1333,
633
+ ),
634
+ (
635
+ 736,
636
+ 1333,
637
+ ),
638
+ (
639
+ 768,
640
+ 1333,
641
+ ),
642
+ (
643
+ 800,
644
+ 1333,
645
+ ),
646
+ ],
647
+ type='RandomChoiceResize'),
648
+ ],
649
+ ],
650
+ type='RandomChoice'),
651
+ dict(type='PackDetInputs'),
652
+ ],
653
+ type='CocoDataset'),
654
+ num_workers=2,
655
+ persistent_workers=True,
656
+ sampler=dict(_scope_='mmdet', shuffle=True, type='DefaultSampler'))
657
+ train_pipeline = [
658
+ dict(backend_args=None, type='LoadImageFromFile'),
659
+ dict(type='LoadAnnotations', with_bbox=True),
660
+ dict(prob=0.5, type='RandomFlip'),
661
+ dict(
662
+ transforms=[
663
+ [
664
+ dict(
665
+ keep_ratio=True,
666
+ scales=[
667
+ (
668
+ 480,
669
+ 1333,
670
+ ),
671
+ (
672
+ 512,
673
+ 1333,
674
+ ),
675
+ (
676
+ 544,
677
+ 1333,
678
+ ),
679
+ (
680
+ 576,
681
+ 1333,
682
+ ),
683
+ (
684
+ 608,
685
+ 1333,
686
+ ),
687
+ (
688
+ 640,
689
+ 1333,
690
+ ),
691
+ (
692
+ 672,
693
+ 1333,
694
+ ),
695
+ (
696
+ 704,
697
+ 1333,
698
+ ),
699
+ (
700
+ 736,
701
+ 1333,
702
+ ),
703
+ (
704
+ 768,
705
+ 1333,
706
+ ),
707
+ (
708
+ 800,
709
+ 1333,
710
+ ),
711
+ ],
712
+ type='RandomChoiceResize'),
713
+ ],
714
+ [
715
+ dict(
716
+ keep_ratio=True,
717
+ scales=[
718
+ (
719
+ 400,
720
+ 4200,
721
+ ),
722
+ (
723
+ 500,
724
+ 4200,
725
+ ),
726
+ (
727
+ 600,
728
+ 4200,
729
+ ),
730
+ ],
731
+ type='RandomChoiceResize'),
732
+ dict(
733
+ allow_negative_crop=True,
734
+ crop_size=(
735
+ 384,
736
+ 600,
737
+ ),
738
+ crop_type='absolute_range',
739
+ type='RandomCrop'),
740
+ dict(
741
+ keep_ratio=True,
742
+ scales=[
743
+ (
744
+ 480,
745
+ 1333,
746
+ ),
747
+ (
748
+ 512,
749
+ 1333,
750
+ ),
751
+ (
752
+ 544,
753
+ 1333,
754
+ ),
755
+ (
756
+ 576,
757
+ 1333,
758
+ ),
759
+ (
760
+ 608,
761
+ 1333,
762
+ ),
763
+ (
764
+ 640,
765
+ 1333,
766
+ ),
767
+ (
768
+ 672,
769
+ 1333,
770
+ ),
771
+ (
772
+ 704,
773
+ 1333,
774
+ ),
775
+ (
776
+ 736,
777
+ 1333,
778
+ ),
779
+ (
780
+ 768,
781
+ 1333,
782
+ ),
783
+ (
784
+ 800,
785
+ 1333,
786
+ ),
787
+ ],
788
+ type='RandomChoiceResize'),
789
+ ],
790
+ ],
791
+ type='RandomChoice'),
792
+ dict(type='PackDetInputs'),
793
+ ]
794
+ val_cfg = dict(_scope_='mmdet', type='ValLoop')
795
+ val_dataloader = dict(
796
+ batch_size=2,
797
+ dataset=dict(
798
+ _scope_='mmdet',
799
+ ann_file='annotations/instances_val.json',
800
+ backend_args=None,
801
+ data_prefix=dict(img='val/'),
802
+ data_root='/home/worawit.tepsan/Project_AI/Detection/data',
803
+ metainfo=dict(classes='license_plate'),
804
+ pipeline=[
805
+ dict(backend_args=None, type='LoadImageFromFile'),
806
+ dict(keep_ratio=True, scale=(
807
+ 1333,
808
+ 800,
809
+ ), type='Resize'),
810
+ dict(type='LoadAnnotations', with_bbox=True),
811
+ dict(
812
+ meta_keys=(
813
+ 'img_id',
814
+ 'img_path',
815
+ 'ori_shape',
816
+ 'img_shape',
817
+ 'scale_factor',
818
+ ),
819
+ type='PackDetInputs'),
820
+ ],
821
+ test_mode=True,
822
+ type='CocoDataset'),
823
+ drop_last=False,
824
+ num_workers=2,
825
+ persistent_workers=True,
826
+ sampler=dict(_scope_='mmdet', shuffle=False, type='DefaultSampler'))
827
+ val_evaluator = dict(
828
+ _scope_='mmdet',
829
+ ann_file=
830
+ '/home/worawit.tepsan/Project_AI/Detection/data/annotations/instances_val.json',
831
+ backend_args=None,
832
+ format_only=False,
833
+ metric='bbox',
834
+ type='CocoMetric')
835
+ val_pipeline = [
836
+ dict(backend_args=None, type='LoadImageFromFile'),
837
+ dict(keep_ratio=True, scale=(
838
+ 1333,
839
+ 800,
840
+ ), type='Resize'),
841
+ dict(type='LoadAnnotations', with_bbox=True),
842
+ dict(
843
+ meta_keys=(
844
+ 'img_id',
845
+ 'img_path',
846
+ 'ori_shape',
847
+ 'img_shape',
848
+ 'scale_factor',
849
+ ),
850
+ type='PackDetInputs'),
851
+ ]
852
+ vis_backends = [
853
+ dict(_scope_='mmdet', type='LocalVisBackend'),
854
+ ]
855
+ visualizer = dict(
856
+ _scope_='mmdet',
857
+ name='visualizer',
858
+ type='DetLocalVisualizer',
859
+ vis_backends=[
860
+ dict(type='LocalVisBackend'),
861
+ ])
862
+ work_dir = '/home/worawit.tepsan/Project_AI/Detection/object_detection/workdir'
epoch_12.pth ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:87be24bdab40769b9811906b18e59a7d0272708352fe578822e761a5e5984949
3
+ size 2883789421