facebookresearch / supervision-by-registration

Supervision-by-Registration: An Unsupervised Approach to Improve the Precision of Facial Landmark Detectors
Other
762 stars 165 forks source link

replace the backbone #58

Open AaronXinWu opened 5 years ago

AaronXinWu commented 5 years ago

hello, D-X-Y. Thanks for your nice model, it works really stable on videos. Further, when trying to replace the backbone 'VGG16' with ‘MobileNet V3’. An error occured:

Configure(optimizer='sgd', LR=5e-05, momentum=0.9, Decay=0.0005, nesterov=True, criterion='MSE-none', loss_norm=True, lossnorm=True, epochs=50, schedule=[30, 40], gamma=0.5) Traceback (most recent call last): File "./exps/basic_main.py", line 183, in main(args) File "./exps/basic_main.py", line 113, in main optimizer, scheduler, criterion = obtain_optimizer(net_param_dict, opt_config, logger) File "/data/zxh/aaron/supervision-by-registration-mobilenetv3/lib/optimizer/opt_utils.py", line 14, in obtain_optimizer weight_decay=config.Decay, nesterov=config.nesterov) File "/data/zxh/anaconda3/envs/python36/lib/python3.6/site-packages/torch/optim/sgd.py", line 64, in init super(SGD, self).init(params, defaults) File "/data/zxh/anaconda3/envs/python36/lib/python3.6/site-packages/torch/optim/optimizer.py", line 43, in init self.add_param_group(param_group) File "/data/zxh/anaconda3/envs/python36/lib/python3.6/site-packages/torch/optim/optimizer.py", line 191, in add_param_group "but one of the params is " + torch.typename(param))

I wonder if there are some other related files or parameters need to be modified,I will approciate it if you can provide some info.

D-X-Y commented 5 years ago

In my opinion, you only need to modify the model file. It seems that your parameters (which fed into optimizer) have something wrong, https://github.com/facebookresearch/supervision-by-registration/blob/master/exps/basic_main.py#L111

AaronXinWu commented 5 years ago

Hi, D-X-Y. Thanks for your good advice. The model worked out. By the way. I wonder how to apply this model to unlabeled videos or images.

  1. ‘vis.py’ seems directly make use of the result of evaluation during training.(Unfortunately, my own unlabeled video could not be put into eval data)
  2. 'eval.py' need to provide the coordinate of the face in advance , which is unavailable in my own raw video.
qdushuaicao commented 3 years ago

Hi, D-X-Y. Thanks for your good advice. The model worked out. By the way. I wonder how to apply this model to unlabeled videos or images.

  1. ‘vis.py’ seems directly make use of the result of evaluation during training.(Unfortunately, my own unlabeled video could not be put into eval data)
  2. 'eval.py' need to provide the coordinate of the face in advance , which is unavailable in my own raw video.

Hi,D-X-Y.I trying to replace the backbone 'VGG16' with ‘MobileNet V3’.I met the same problem as you, how did you solve it?Looking forward to your reply ,thanks.

qdushuaicao commented 3 years ago

Hi, D-X-Y. Thanks for your good advice. The model worked out. By the way. I wonder how to apply this model to unlabeled videos or images.

  1. ‘vis.py’ seems directly make use of the result of evaluation during training.(Unfortunately, my own unlabeled video could not be put into eval data)
  2. 'eval.py' need to provide the coordinate of the face in advance , which is unavailable in my own raw video.

Hi, AaronXinWu.I trying to replace the backbone 'VGG16' with ‘MobileNet V3’.I met the same problem as you, how did you solve it?Looking forward to your reply ,thanks.

qdushuaicao commented 3 years ago

在修改替换网络时,不设置bias参数,可解决上述问题。

qdushuaicao commented 3 years ago

Hi, D-X-Y. Thanks for your good advice. The model worked out. By the way. I wonder how to apply this model to unlabeled videos or images.

  1. ‘vis.py’ seems directly make use of the result of evaluation during training.(Unfortunately, my own unlabeled video could not be put into eval data)
  2. 'eval.py' need to provide the coordinate of the face in advance , which is unavailable in my own raw video. 您好!请问您修改后模型的效果如何?