bingykang / Fewshot_Detection

Few-shot Object Detection via Feature Reweighting
https://arxiv.org/abs/1812.01866
526 stars 111 forks source link

Hi, few shot tuning #11

Closed bitwangdan closed 4 years ago

bitwangdan commented 4 years ago

Thank you very much for your code, which is very interesting. But I have a question, This is the result of my base training image This is the result of my few shot tuning image The MAP of novel class is better , but the base class is worse, is there something wrong?

liuzhuang13 commented 4 years ago

Did you fine-tune with both novel & base classes or just novel classes?

bingykang commented 4 years ago

If you are using my code and config file without any change, you should test the fifth checkpoint or change "max_epoch" in "metatune.data" to 1000 instead of 2000 for 5-shot detection.

bitwangdan commented 4 years ago

Did you fine-tune with both novel & base classes or just novel classes?

image Hi, I have a question, what does this weightfile mean? is the result of base training?

bitwangdan commented 4 years ago

If you are using my code and config file without any change, you should test the fifth checkpoint or change "max_epoch" in "metatune.data" to 1000 instead of 2000 for 5-shot detection.

Hi,I trained according to your steps, image and what does this weightfile mean?

bitwangdan commented 4 years ago

If you are using my code and config file without any change, you should test the fifth checkpoint or change "max_epoch" in "metatune.data" to 1000 instead of 2000 for 5-shot detection. Hi, This is the way I tested before: (1) python valid_ensemble.py cfg/metatune.data cfg/darknet_dynamic.cfg cfg/reweighting_net.cfg backup/metatunetest1_novel0_neg0/000010.weights (2) python scripts/voc_eval.py results/metatunetest1_novel0_neg0/ene000010/comp4_dettest

I changed the 000010.weights to 000005.weights, but the result is also like this.

XinyiYS commented 4 years ago

Got the same problem as @bitwangdan . The final evaluated results are not the same as @bitwangdan reproduced here, but are similar

Screenshot 2019-11-01 at 4 26 11 PM

I have also tried with changing 000010.weights to 00000x.weights, and the evaluation results stay the same.

m10507323 commented 4 years ago

@bitwangdan @XinyiYS Hi, can I ask how to install pytorch 0.3.1 with python2.7? Because the error said I can't install numpy in python2.7, and the python version need >=3.5 when I install torch and torchvision. Do you have this problem when implement the source code? Thanks.

futureisatyourhand commented 4 years ago

Got the same problem as @bitwangdan . The final evaluated results are not the same as @bitwangdan reproduced here, but are similar

Screenshot 2019-11-01 at 4 26 11 PM

I have also tried with changing 000010.weights to 00000x.weights, and the evaluation results stay the same. You should carefully analyze the eval code, and you should delete the annts.pkl file when you evaluate it, and the evaluation result is the current result.

Got the same problem as @bitwangdan . The final evaluated results are not the same as @bitwangdan reproduced here, but are similar

Screenshot 2019-11-01 at 4 26 11 PM

I have also tried with changing 000010.weights to 00000x.weights, and the evaluation results stay the same.

You should carefully analyze the eval code, and you should delete the annts.pkl file when you evaluate it, and the evaluation result is the current result.

futureisatyourhand commented 4 years ago

与@bitwangdan遇到相同的问题。最终评估结果与此处复制的@bitwangdan不同,但相似

屏幕截图2019-11-01在4 26 11 PM

我还尝试将000010.weights更改为00000x.weights,并且评估结果保持不变。

Got the same problem as @bitwangdan . The final evaluated results are not the same as @bitwangdan reproduced here, but are similar

Screenshot 2019-11-01 at 4 26 11 PM

I have also tried with changing 000010.weights to 00000x.weights, and the evaluation results stay the same.

Excuse me, is your training setting exactly the same as the author? Thanks!

XinyiYS commented 4 years ago

Excuse me, is your training setting exactly the same as the author?

Yes, I followed the configurations and the setting by the repo exactly. The results after base training were on par with the author's results. But I cannot seem to get as good results after few-shot fine-tune as the author's results.

On a side-node about Github: why, all of a sudden, am I reading some sort-of mandarin translation of my previous comment? lol

futureisatyourhand commented 4 years ago

Excuse me, is your training setting exactly the same as the author?

Yes, I followed the configurations and the setting by the repo exactly. The results after base training were on par with the author's results. But I cannot seem to get as good results after few-shot fine-tune as the author's results.

On a side-node about Github: why, all of a sudden, am I reading some sort-of mandarin translation of my previous comment? lol

When I train 1500 epochs by two 1080Ti GPUs, The best base class evaluation result is shown. author_1130 and I don't know why the base result is poor. Are you train base model with four GPUs? Thanks your reply!

XinyiYS commented 4 years ago

Excuse me, is your training setting exactly the same as the author?

Yes, I followed the configurations and the setting by the repo exactly. The results after base training were on par with the author's results. But I cannot seem to get as good results after few-shot fine-tune as the author's results. On a side-node about Github: why, all of a sudden, am I reading some sort-of mandarin translation of my previous comment? lol

When I train 1500 epochs by two 1080Ti GPUs, The best base class evaluation result is shown. author_1130 and I don't know why the base result is poor. Are you train base model with four GPUs? Thanks your reply!

Is this after base training alone, or after base training AND fine tuning?

Yeah, I carried our the base training with four GPUs.

futureisatyourhand commented 4 years ago

Excuse me, is your training setting exactly the same as the author?

Yes, I followed the configurations and the setting by the repo exactly. The results after base training were on par with the author's results. But I cannot seem to get as good results after few-shot fine-tune as the author's results. On a side-node about Github: why, all of a sudden, am I reading some sort-of mandarin translation of my previous comment? lol

When I train 1500 epochs by two 1080Ti GPUs, The best base class evaluation result is shown. author_1130 and I don't know why the base result is poor. Are you train base model with four GPUs? Thanks your reply!

Is this after base training alone, or after base training AND fine tuning?

Yeah, I carried our the base training with four GPUs. this is the base training alone

XinyiYS commented 4 years ago

this is the base training alone

Not sure if using 2 GPUs instead of 4 would affect the effectiveness of training. Probably the authors are best equipped to answer your questions.

Naively, i think you might try loading the last weights file of the model and continue with base training for some more epochs and see if the evaluation results improve. In my opinion, the base training should not cause much trouble since the it relies more on YOLOv2 and darknet back-bone and is essentially training a normal supervised learning object detection model with well-tested architecture (YOLOv2).

futureisatyourhand commented 4 years ago

this is the base training alone

Not sure if using 2 GPUs instead of 4 would affect the effectiveness of training. Probably the authors are best equipped to answer your questions.

Naively, i think you might try loading the last weights file of the model and continue with base training for some more epochs and see if the evaluation results improve. In my opinion, the base training should not cause much trouble since the it relies more on YOLOv2 and darknet back-bone and is essentially training a normal supervised learning object detection model with well-tested architecture (YOLOv2).

Thank your reply, I will continue to train the base.

XinyiYS commented 4 years ago

Thank your reply, I will continue to train the base.

I shared the my trained model (only after base training), here #19 Maybe you could the weights directly instead of trying to figure out how to get the base training to work.

futureisatyourhand commented 4 years ago

Thank your reply, I will continue to train the base.

I shared the my trained model (only after base training), here #19 Maybe you could the weights directly instead of trying to figure out how to get the base training to work.

Thank your suggestion, I mainly use this method for other work and improve the performance. In a short, thank you very much!

futureisatyourhand commented 4 years ago

Thank your reply, I will continue to train the base.

I shared the my trained model (only after base training), here #19 Maybe you could the weights directly instead of trying to figure out how to get the base training to work.

Hello, what is the configuration of your server environment? As configured by the author, I train 150 epochs, but the detection result is much worse than yours for base classes. Thank your reply!

futureisatyourhand commented 4 years ago

Thank you very much for your code, which is very interesting. But I have a question, This is the result of my base training image This is the result of my few shot tuning image The MAP of novel class is better , but the base class is worse, is there something wrong?

Hello, how many epochs do you train this result on the base class? Thanks~

XinyiYS commented 4 years ago

Hello, what is the configuration of your server environment? As configured by the author, I train 150 epochs, but the detection result is much worse than yours for base classes. Thank your reply!

I followed the author's config and environment pretty much exactly. So I am not very sure why training on different servers results quite different results. Perhaps run through the path to your downloaded datasets to make sure there is no hidden bugs.

infrontofme commented 4 years ago

Hi, Have new classes been used to train the base model?