IDEA-Research / DWPose

"Effective Whole-body Pose Estimation with Two-stages Distillation" (ICCV 2023, CV4Metaverse Workshop)
Apache License 2.0
2.19k stars 141 forks source link

The ckpt of the second stage distillation #62

Closed l-dawei closed 9 months ago

l-dawei commented 9 months ago

Hello.

Is the teacher_pretrained used in the second training the same as the ckpt obtained in the first train stage?

Who can help me?

# method details
model = dict(
    _delete_ = True,
    type='PoseEstimatorDistiller',
    two_dis = second_dis,
    teacher_pretrained = 'work_dirs/rtmpose_x_dis_l__coco-ubody-256x192/dw-x-l_ucoco.pth',
    teacher_cfg = 'configs/wholebody_2d_keypoint/rtmpose/ubody/rtmpose-l_8xb64-270e_coco-ubody-wholebody-256x192.py',
    student_cfg = 'configs/wholebody_2d_keypoint/rtmpose/ubody/rtmpose-l_8xb64-270e_coco-ubody-wholebody-256x192.py',
    distill_cfg = [
                    dict(methods=[dict(type='KDLoss',
                                       name='loss_logit',
                                       use_this = logit,
                                       weight = 1,
                                       )
                                ]
                        ),
                    ],
    data_preprocessor=dict(
        type='PoseDataPreprocessor',
        mean=[123.675, 116.28, 103.53],
        std=[58.395, 57.12, 57.375],
        bgr_to_rgb=True),
    train_cfg=train_cfg,
)
yzd-v commented 9 months ago

Yes, you can use the ckpt obtained from the first distillation stage or the baseline training. Both two models are fine.