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

A question about the code #1

Open
anonymousiccv opened this issue Dec 11, 2020 · 4 comments
Open

A question about the code #1

anonymousiccv opened this issue Dec 11, 2020 · 4 comments

Comments

@anonymousiccv
Copy link

Hi Wei, can you tell me why the ce losses are multiplied by 0.00001?
cls_loss_0 = 0.00001 * cross_entropy_losses(im_cls_prob_0, labels.type(im_cls_prob_0.dtype))

@vasgaowei
Copy link
Owner

For different MIL Learners, their localizers output instance localization scores respectively. For Localization Completeness, we add discrepancy loss among these instance localization scores. But this may hurt the instance localization ability of some localizers, meanwhile deteriorate the detection performance and image classification ability of MIL Learners. So we add cls_loss_0 = cross_entropy_losses(im_cls_prob_0, labels.type(im_cls_prob_0.dtype)). However, we find that cls_loss_0and cls_loss_1 could enforce the similiraty of localization scores of different MIL Learners which decreases the Localization Completeness and increases the Localization Redundancy. So the ce losses are multiplied by 0.00001 (0.0001 is also valided in our experiment which show comparable performance with 0.00001). Then cls_loss_0 = 0.00001 * cross_entropy_losses(im_cls_prob_0, labels.type(im_cls_prob_0.dtype)).

@anonymousiccv
Copy link
Author

Thanks very much!
One more question. Is the implementation of PCL same as the official one?
How could we test the standard PCL via this repo?

@vasgaowei
Copy link
Owner

Our implementation of PCL is almost the same as the official one PCL, expect that our codes are more concise and less complicated. Besides, the method of getting the cluster centers is a little different. There are two ways of getting the cluster centers as mentioned in paper PCL:

  1. Finding proposal cluster centers using the highest scoring proposal
  2. Finding proposal cluster centers using graphs of top ranking proposals

And in our implementation of PCL, we just choose the first method that selecting the highest scoring proposals as the proposal cluster centers.

And for testing the standard PCL via this repo, we may modify codes for getting proposal cluster centers. For example, now in D-MIL, the code is instane_selector or get_highest_score_proposals. We can replace it with code borrowed from this link PCL.

@vasgaowei
Copy link
Owner

vasgaowei commented Dec 30, 2020

I will upload another branch for testing the standard PCL method soon.

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

2 participants