ROMP icon indicating copy to clipboard operation
ROMP copied to clipboard

Some questions regarding pretraining

Open mkhoshle opened this issue 3 years ago • 1 comments

Hello,

I have several questions regarding the pretraining phase. I would like to use pre-trained hrnet or resnet50 models.

  1. the pretrain_hrnet.pkl mentioned in many previous issues is not in the repository. Could you please tell me where I can find it? I believe this is made by you.
  2. Does pretrain_hrnet.pkl contain backbone parameters only?
  3. The pretrain_hrnet.pkl path should be provided to hrnet_pretrain parameter in v1.yml. Is that correct? I am confused about this because in this issue you mention resnet_pretrain should be set while in the other one you mention model_path should be set. model_path is for trained ROMP model. Is not it? So for pertaining either hrnet_pretrain or resnet_pretrain should be set.
  4. Also in the val_result function you have the following line:
    if self.backbone == 'resnet':
        eval_model.train()
    else:
        eval_model.eval()

Why do you train the model during evaluation for resnet and not for hrnet?

I would really appreciate it if you could help me with this questions.

mkhoshle avatar Aug 11 '22 22:08 mkhoshle

HI,

  1. Download link https://github.com/Arthur151/ROMP/releases/download/v1.1/trained_models.zip
  2. Yes, it only contains backbone parameters.
  3. If you already set hrnet_pretrain, then it could be properly loaded via https://github.com/Arthur151/ROMP/blob/d78880a1c56bd92df7e8f28d5d5aa19c6b7106f6/romp/lib/models/romp_model.py#L34 If you also set fine_tune=False
  4. I found that resnet-based model would perform normaly during evaluation if we set it to train() mode, otherwise, eval() mode would significantly decrease the evaluation matrix numbers.

Arthur151 avatar Aug 12 '22 14:08 Arthur151

Hi @Arthur151,

I have a question for you. If I want to evaluate the performance of the pre-trained backbones pretrain_hrnet.pkl and pretrain_resnet.pkl what would be the best way given that they are a smaller part of the model that has been cut and the rest is not available?

Based on your previous comments, code for the pre-trained model is not available and the pretrain_hrnet.pkl and pretrain_resnet.pkl are part of that model. What is your suggestion for evaluating the detection and 2d-pose estimation performance?

mkhoshle avatar Oct 28 '22 13:10 mkhoshle