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

Top-1 Loc, Top-5 Loc and backbone( DenseNet161 and EfficientNet-B7 ) #5

Open
rjy-fighting opened this issue Jul 25, 2022 · 17 comments

Comments

@rjy-fighting
Copy link

Hello! First of all, you did a great job! Congratulations! Second, I have three questions I'd like to ask you about running the code.

  1. First, in the case of WSOL, I didn't find the test file test.py in the code. Is the result on the CUB-200-2011 test set and imagenet-1k validation set mentioned in this paper calculated by def test in train_ccam_cub. py?
    屏幕截图 2022-07-25 171210

  2. Secondly, the three evaluation Top-1 Loc, Top-5 Loc mentioned in the paper were not found in the code to calculate Top-1 Loc and Top-5 Loc, so there was no Top-1 Loc and Top-5 Loc in the running result of my CUB-200-2011 dataset. How to solve this problem?
    屏幕截图 2022-07-25 171357(1)

  3. Thirdly, the C2AM(Ours) in Table1 uses backbone DenseNet161 and Efficientnet-B7. I did not find the part of the code downloading and replacing these two backbone networks in the code, so that the results in C2AM(Ours) in Table1 could not be reproduced. How to solve this problem?
    屏幕截图 2022-07-25 171357(2)

@Sierkinhane
Copy link
Member

Sierkinhane commented Jul 25, 2022

Hi,

  1. This repository only provide the training code for CCAM (train_CCAM_CUB. py/train_CCAM_ILSVRC. py and test codes were included in them)
  2. After training of CCAM, you can extract class-agnostic bouding boxes from CCAM and re-train a regressor using these pseudo bboxes. Please refer to sec 3.4. in our paper.
  3. You can adopt DenseNet as the backbone for localization and efficientnet for classification (just following other works' setting like PSOL). Code was provided at here. I will try my best to open my code in this repository for re-training.
  4. Btw, the simplest method to get top-1 loc and top-5 loc is to directly combine class-agnostic bboxes estimated from CCAM and classification from a classifer. Code for top-1 and top-5 loc you can refer to my another repository https://github.com/Sierkinhane/ORNet/blob/59e8ef5e461a5b00ca8c94d9fa0f5e58df193774/train_2nd_step.py#L225

BTW, welcome to star our project!

@rjy-fighting
Copy link
Author

Thanks for your reply! I would like to confirm the following questions with you again. For the second question, I need to manually add the top-1 and top-5 code to the source code, right? For the third question, I need to refer to PSOL to modify and add the source code to re-train and achieve the following result reproduction, right?

屏幕截图 2022-07-25 171357(2)

I really appreciate your work, hope you can open your re-training code in this repository, and I have strat for your work!

@Sierkinhane
Copy link
Member

Exactly.

@Sierkinhane
Copy link
Member

For convenience, I will try to clean and upload my codes in the coming weeks!

@rjy-fighting
Copy link
Author

Ok, thank you very much for your reply!

@Sierkinhane
Copy link
Member

Hello, I just clean and upload the code to train a regressor using the extracted bboxes. Please check that and feel free to ask any questions!

@rjy-fighting
Copy link
Author

Ok, I'll download the code and take a look. Thank you for your patient and careful reply! Your work is really great! If there are new questions in the future, I hope to communicate with you through the platform! Thank you!

@rjy-fighting
Copy link
Author

Hello, I just clean and upload the code to train a regressor using the extracted bboxes. Please check that and feel free to ask any questions!

Hello, I would like to know the configuration of your WSOL and WSSS experiments, as well as the epochs when training WSOL on CUB_200_2011 dataset and WSSS on VOC2012.

@Sierkinhane
Copy link
Member

Hello, default configurations can be found in xxx.yaml or arguments in the code.

@rjy-fighting
Copy link
Author

Sorry, after running the three steps of the PY file according to README in WSSS, the background clue I get is like this, I can't see the outline of the target at all, it is almost completely black. But I follow the README operation, only changed the path of the dataset and the name of the model, I don't know what is wrong?😭
Please help me!😭
2007_000170-1
2007_000170
2007_000241-1
2007_000241
2007_000256-1
2007_000256

@Sierkinhane
Copy link
Member

Have you loaded the pretrained moco or detco?

@Sierkinhane
Copy link
Member

When runing the experiments, you can observe the generated activation map in experiments/images/.
├── experiments/
| ├── checkpoints
| ├—— images

@rjy-fighting
Copy link
Author

Hello, default configurations can be found in xxx.yaml or arguments in the code.

Hello, I see that the loss value of ten epochs is still decreasing. Should we increase the training epoch? As for the background clue being all black, I may need some more time to experiment.

@Sierkinhane
Copy link
Member

I just run the code and it is no problem in my experiments. How about your configurations? Is same with this repository?

@Sierkinhane
Copy link
Member

Please ensure the batch size is larger than 32.

@LinSY546749
Copy link

LinSY546749 commented Apr 17, 2023

  1. Btw, the simplest method to get top-1 loc and top-5 loc is to directly combine class-agnostic bboxes estimated from CCAM and classification from a classifer. Code for top-1 and top-5 loc you can refer to my another repository https://github.com/Sierkinhane/ORNet/blob/59e8ef5e461a5b00ca8c94d9fa0f5e58df193774/train_2nd_step.py#L225

Hello,I'm confused about how to calculate top-1 loc and top-5 loc on top of class-agnostic maps since class label is unknown, could you explained classifer in detail?For example,whether the classifer is directly bulit on the class-agnostic maps? And whether the classifier needs to be supervised?

@Sierkinhane
Copy link
Member

Hi, just combine the bbox with a classification result. We provide details in method section.

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

3 participants