Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The code for localization #2

Open
jianpursuit opened this issue Sep 8, 2018 · 13 comments
Open

The code for localization #2

jianpursuit opened this issue Sep 8, 2018 · 13 comments

Comments

@jianpursuit
Copy link

Is there code for finding b-box and measuring localization accuracy?

@xiaomengyc
Copy link
Owner

I use the code from CAM(https://github.com/metalbubble/CAM) for producing boxes and measuring localization accuracy.

@jianpursuit
Copy link
Author

I get, thanks a lot.

@chaoyan1037
Copy link

Hi @xiaomengyc ,

Thanks for sharing your code! As I am running your code, I get a similar classification error on CUB dataset. However, when it comes to the localization error, I get a much higher localization error. So I look into the CAM code, and find there are three threshold values. As I change the threshold value, I can get better results. Did you use the provided thresholds [20, 100, 110], or you used another threshold values? Thanks.

@chaoyan1037
Copy link

Hi @xiaomengyc ,

Thanks for sharing your code! As I am running your code, I get a similar classification error on CUB dataset. However, when it comes to the localization error, I get a much higher localization error. So I look into the CAM code, and find there are three threshold values. As I change the threshold value, I can get better results. Did you use the provided thresholds [20, 100, 110], or you used another threshold values? Thanks.

@xiaomengyc
Copy link
Owner

Hi @xiaomengyc ,

Thanks for sharing your code! As I am running your code, I get a similar classification error on CUB dataset. However, when it comes to the localization error, I get a much higher localization error. So I look into the CAM code, and find there are three threshold values. As I change the threshold value, I can get better results. Did you use the provided thresholds [20, 100, 110], or you used another threshold values? Thanks.

I tested different thresholds to obtain the best localization results. I am sorry that I forgot the exact threshold numbers.

@chaoyan1037
Copy link

@xiaomengyc
Thanks for your kind reply! It is fine. It great to know how you set the threshold values. Thanks again!

@chaoyan1037
Copy link

@xiaomengyc
One more question, since I have run your code and tried different thresholds, I can not get the reported localization results, though I did get a similar classification result. So I think the model is well trained.
What really matters here is the threshold values. If it possible for you to find out the threshold values in your code? I will be very appreciated if you can do that. Thanks a lot.

@chaoyan1037
Copy link

Actually, when I use ground truth labels to evaluate, I can get the similar localization results as you reported. However, the classification error rate is about ~25, which means the localization error will be much worse than you reported.

@xiaomengyc
Copy link
Owner

Hi @chaoyan1037 ,
Sorry for the missing threshold values. I looked through my experiment records but still did not find these values. It seems I only picked out the best results, since I used a script to run over many possible combinations.
The localization results using ground truth labels are fairer for comparison. It makes sense if there are some little difference. Also, the results reported in the paper are obtained in Tensorflow. Maybe this will cause some difference as well.

@chaoyan1037
Copy link

Hi @xiaomengyc
Thanks for the reply! Your code has helped me to understand this task and thanks a lot for the code!

@chaoyan1037
Copy link

Hi @xiaomengyc ,
One last question, hope you will not feel annoying. Since I am new to this topic, I am not sure my evaluation method is right. First of all, for each image, we can use CAM to generate multiple bound boxes. Which one do you use for the evaluation? I just select the first one for the evaluation. Secondly, I use the ILSVRC 2012 dataset while you use the ILSVRC 2016. Is there any difference? Thanks for your patience and help!

@Rahul-Venugopal
Copy link

Hi @jianpursuit , @xiaomengyc , @chaoyan1037 ,

I am currently searching for a solution to create bounding boxes on an image where training data does not contain any annotations. Is it possible to use this code for doing the same ?. I am trying to create training data for YOLO .

(PS : I am new to this field and please excuse me if my questions are too vague )

Thanks
Rahul

@xiaomengyc
Copy link
Owner

@xiaomengyc
ACoL is exactly designed for the weakly supervised localization problem. It actually learns a classification network with the supervision of image level labels (like cat or dog). We apply the classification network to generate heatmaps indicating where the target objects most likely appear. After getting heatmaps using our code, you got to produce the bounding boxes using the code rom CAM.

Mainwhile, you can also use our SPG model, where provides the trained model on ImageNet. You can try this model first seeing whether this weakly method fits you needs.

Gook Luck!
Xiaolin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants