youngwanLEE / vovnet-detectron2

[CVPR 2020] VoVNet backbone networks for detectron2
Other
374 stars 69 forks source link

How to set the params? such channel #13

Closed DYJ1111 closed 4 years ago

DYJ1111 commented 4 years ago

Hello, I want to change the output channel to be 128, Could you give me some advice about how to modify the params? The params I set can not get a good result. The result is worse than ResNet34.

Looking forward your reply.

youngwanLEE commented 4 years ago

Which one of the output channels?

You can change the channel of FPN like this.

https://github.com/youngwanLEE/vovnet-detectron2/blob/f96f53448a162cd5364ff9d4ef0530c7d9a961a6/configs/faster_rcnn_V_19_FPNLite_3x.yaml#L7-L8

DYJ1111 commented 4 years ago

Which one of the output channels?

You can change the channel of FPN like this.

https://github.com/youngwanLEE/vovnet-detectron2/blob/f96f53448a162cd5364ff9d4ef0530c7d9a961a6/configs/faster_rcnn_V_19_FPNLite_3x.yaml#L7-L8

So you mean that I can use the vovnet VoVNet19_slim_eSE = { 'stem': [64, 64, 128], 'stage_conv_ch': [64, 80, 96, 112], 'stage_out_ch': [112, 256, 384, 512], 'layer_per_block': 3, 'block_per_stage': [1, 1, 1, 1], 'eSE' : True, "dw" : False }as the conv body. when i want to classify, I just map 512 to 128?

youngwanLEE commented 4 years ago

I cannot figure out what you mean.

Please explain more details what you want.

Do you want to use vovnet for image classification task?

DYJ1111 commented 4 years ago

I cannot figure out what you mean.

Please explain more details what you want.

Do you want to use vovnet for image classification task?

I want to do a speech classification task, the embedding size of the classification is set to 128, according to the parameter settings provided in the paper, the embedding size is 512, so I think it is possible to adjust the parameters to make the embedding size generated by the network become 128

youngwanLEE commented 4 years ago

I see,

I recommend

if you want to use the pretrained weight, you don't need to change the original parameter of vovnet. Instead, you add global average pooling - fc with 128 channels.

like ResNet for classification

https://github.com/pytorch/vision/blob/3d65fc6723f1e0709916f24d819d6e17a925b394/torchvision/models/resnet.py#L157-L158

DYJ1111 commented 4 years ago

I see,

I recommend

if you want to use the pretrained weight, you don't need to change the original parameter of vovnet. Instead, you add global average pooling - fc with 128 channels.

like ResNet for classification

https://github.com/pytorch/vision/blob/3d65fc6723f1e0709916f24d819d6e17a925b394/torchvision/models/resnet.py#L157-L158

Are there any training strategies that need attention, such as learning rate and number of iterations?

youngwanLEE commented 4 years ago

@DYJ1111

The training protocols such as learning rate and schedule, etc depend on your task and GPU envrionment.

DYJ1111 commented 4 years ago

@DYJ1111

The training protocols such as learning rate and schedule, etc depend on your task and GPU envrionment.

ok, thank you