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

Code for generating diffused_boxes is not clear #22

Open
skbhat opened this issue May 21, 2024 · 0 comments
Open

Code for generating diffused_boxes is not clear #22

skbhat opened this issue May 21, 2024 · 0 comments

Comments

@skbhat
Copy link

skbhat commented May 21, 2024

Namaste,

Thank you very much for the code. In the following line diffused boxes are created. I have two questions:

  1. The lines previous to this creates many variables which are not used by the function at all. The argument gt_boxes itself is not needed.
  2. I could not understand the logic behind generating boxes in this way.
        x = torch.randn(self.num_proposals, 4, device=self.device)
        x = (x * 2. - 1.) * self.scale
        x = torch.clamp(x, min=-1 * self.scale, max=self.scale)
        x = ((x / self.scale) + 1) / 2.
        diff_boxes = box_cxcywh_to_xyxy(x)
        return diff_boxes

regards

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

1 participant