更换文档检测模型
This commit is contained in:
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_l_300e_battery/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_l_300e_coco.pdparams
|
||||
depth_mult: 1.0
|
||||
width_mult: 1.0
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [512, 544, 576, 608, 640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_l_300e_battery_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_l_300e_coco.pdparams
|
||||
depth_mult: 1.0
|
||||
width_mult: 1.0
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_l_300e_lvjian1/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_l_300e_coco.pdparams
|
||||
depth_mult: 1.0
|
||||
width_mult: 1.0
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.001
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 8
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 1
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_l_300e_lvjian1_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_l_300e_coco.pdparams
|
||||
depth_mult: 1.0
|
||||
width_mult: 1.0
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.001
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 8
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 1
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_l_300e_renche/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_l_300e_coco.pdparams
|
||||
depth_mult: 1.0
|
||||
width_mult: 1.0
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [512, 544, 576, 608, 640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_l_300e_renche_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_l_300e_coco.pdparams
|
||||
depth_mult: 1.0
|
||||
width_mult: 1.0
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_m_300e_battery/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_m_300e_coco.pdparams
|
||||
depth_mult: 0.67
|
||||
width_mult: 0.75
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_m_300e_battery_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_m_300e_coco.pdparams
|
||||
depth_mult: 0.67
|
||||
width_mult: 0.75
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_m_300e_lvjian1/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_m_300e_coco.pdparams
|
||||
depth_mult: 0.67
|
||||
width_mult: 0.75
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.002
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 16
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 1
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_m_300e_lvjian1_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_m_300e_coco.pdparams
|
||||
depth_mult: 0.67
|
||||
width_mult: 0.75
|
||||
|
||||
worker_num: 2
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0015
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 8
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 2
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_m_300e_renche/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_m_300e_coco.pdparams
|
||||
depth_mult: 0.67
|
||||
width_mult: 0.75
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_m_300e_renche_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_m_300e_coco.pdparams
|
||||
depth_mult: 0.67
|
||||
width_mult: 0.75
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: /paddle/dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: /paddle/dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: /paddle/dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_s_300e_battery/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_s_300e_coco.pdparams
|
||||
depth_mult: 0.33
|
||||
width_mult: 0.50
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [512, 544, 576, 608, 640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_s_300e_battery_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_s_300e_coco.pdparams
|
||||
depth_mult: 0.33
|
||||
width_mult: 0.50
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_s_300e_lvjian1/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_s_300e_coco.pdparams
|
||||
depth_mult: 0.33
|
||||
width_mult: 0.50
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.002
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 16
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 1
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_s_300e_lvjian1_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_s_300e_coco.pdparams
|
||||
depth_mult: 0.33
|
||||
width_mult: 0.50
|
||||
|
||||
worker_num: 2
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.003
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 16
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 2
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_s_300e_renche/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_s_300e_coco.pdparams
|
||||
depth_mult: 0.33
|
||||
width_mult: 0.50
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [12, 544, 576, 608, 640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_s_300e_renche_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_s_300e_coco.pdparams
|
||||
depth_mult: 0.33
|
||||
width_mult: 0.50
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_x_300e_battery/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_x_300e_coco.pdparams
|
||||
depth_mult: 1.33
|
||||
width_mult: 1.25
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [512, 544, 576, 608, 640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_x_300e_battery_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_x_300e_coco.pdparams
|
||||
depth_mult: 1.33
|
||||
width_mult: 1.25
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 45
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/train.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: annotations/test.json
|
||||
dataset_dir: dataset/battery_mini
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_x_300e_lvjian1/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_x_300e_coco.pdparams
|
||||
depth_mult: 1.33
|
||||
width_mult: 1.25
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.001
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 8
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 1
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_x_300e_lvjian1/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_x_300e_coco.pdparams
|
||||
depth_mult: 1.33
|
||||
width_mult: 1.25
|
||||
|
||||
worker_num: 2
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 5
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/train
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: images
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: val.json
|
||||
dataset_dir: dataset/slice_lvjian1_data/eval
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 2
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_x_300e_renche/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_x_300e_coco.pdparams
|
||||
depth_mult: 1.33
|
||||
width_mult: 1.25
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 640
|
||||
eval_width: &eval_width 640
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [512, 544, 576, 608, 640, 672, 704, 736, 768], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
@@ -0,0 +1,140 @@
|
||||
weights: output/ppyoloe_crn_x_300e_renche_1024/model_final
|
||||
pretrain_weights: https://paddledet.bj.bcebos.com/models/ppyoloe_crn_x_300e_coco.pdparams
|
||||
depth_mult: 1.33
|
||||
width_mult: 1.25
|
||||
|
||||
worker_num: 4
|
||||
eval_height: &eval_height 1024
|
||||
eval_width: &eval_width 1024
|
||||
eval_size: &eval_size [*eval_height, *eval_width]
|
||||
|
||||
metric: COCO
|
||||
num_classes: 22
|
||||
|
||||
TrainDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: train.json
|
||||
dataset_dir: dataset/renche
|
||||
data_fields: ['image', 'gt_bbox', 'gt_class', 'is_crowd']
|
||||
|
||||
EvalDataset:
|
||||
!COCODataSet
|
||||
image_dir: train_images
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
TestDataset:
|
||||
!ImageFolder
|
||||
anno_path: test.json
|
||||
dataset_dir: dataset/renche
|
||||
|
||||
epoch: 30
|
||||
LearningRate:
|
||||
base_lr: 0.0005
|
||||
schedulers:
|
||||
- !CosineDecay
|
||||
max_epochs: 36
|
||||
- !LinearWarmup
|
||||
start_factor: 0.
|
||||
epochs: 3
|
||||
|
||||
TrainReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- RandomFlip: {}
|
||||
batch_transforms:
|
||||
- BatchRandomResize: {target_size: [960, 992, 1024, 1056, 1088], random_size: True, random_interp: True, keep_ratio: False}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
- PadGT: {}
|
||||
batch_size: 4
|
||||
shuffle: true
|
||||
drop_last: true
|
||||
use_shared_memory: true
|
||||
collate_batch: true
|
||||
|
||||
EvalReader:
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 2
|
||||
|
||||
TestReader:
|
||||
inputs_def:
|
||||
image_shape: [3, *eval_height, *eval_width]
|
||||
sample_transforms:
|
||||
- Decode: {}
|
||||
- Resize: {target_size: *eval_size, keep_ratio: False, interp: 2}
|
||||
- NormalizeImage: {mean: [0.485, 0.456, 0.406], std: [0.229, 0.224, 0.225], is_scale: True}
|
||||
- Permute: {}
|
||||
batch_size: 1
|
||||
|
||||
use_gpu: true
|
||||
use_xpu: false
|
||||
log_iter: 100
|
||||
save_dir: output
|
||||
snapshot_epoch: 5
|
||||
print_flops: false
|
||||
|
||||
# Exporting the model
|
||||
export:
|
||||
post_process: True # Whether post-processing is included in the network when export model.
|
||||
nms: True # Whether NMS is included in the network when export model.
|
||||
benchmark: False # It is used to testing model performance, if set `True`, post-process and NMS will not be exported.
|
||||
|
||||
OptimizerBuilder:
|
||||
optimizer:
|
||||
momentum: 0.9
|
||||
type: Momentum
|
||||
regularizer:
|
||||
factor: 0.0005
|
||||
type: L2
|
||||
|
||||
architecture: YOLOv3
|
||||
norm_type: sync_bn
|
||||
use_ema: true
|
||||
ema_decay: 0.9998
|
||||
|
||||
YOLOv3:
|
||||
backbone: CSPResNet
|
||||
neck: CustomCSPPAN
|
||||
yolo_head: PPYOLOEHead
|
||||
post_process: ~
|
||||
|
||||
CSPResNet:
|
||||
layers: [3, 6, 6, 3]
|
||||
channels: [64, 128, 256, 512, 1024]
|
||||
return_idx: [1, 2, 3]
|
||||
use_large_stem: True
|
||||
|
||||
CustomCSPPAN:
|
||||
out_channels: [768, 384, 192]
|
||||
stage_num: 1
|
||||
block_num: 3
|
||||
act: 'swish'
|
||||
spp: true
|
||||
|
||||
PPYOLOEHead:
|
||||
fpn_strides: [32, 16, 8]
|
||||
grid_cell_scale: 5.0
|
||||
grid_cell_offset: 0.5
|
||||
static_assigner_epoch: 100
|
||||
use_varifocal_loss: True
|
||||
loss_weight: {class: 1.0, iou: 2.5, dfl: 0.5}
|
||||
static_assigner:
|
||||
name: ATSSAssigner
|
||||
topk: 9
|
||||
assigner:
|
||||
name: TaskAlignedAssigner
|
||||
topk: 13
|
||||
alpha: 1.0
|
||||
beta: 6.0
|
||||
nms:
|
||||
name: MultiClassNMS
|
||||
nms_top_k: 1000
|
||||
keep_top_k: 100
|
||||
score_threshold: 0.01
|
||||
nms_threshold: 0.6
|
||||
Reference in New Issue
Block a user