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

is this result correct? #38

Open
sang0775 opened this issue Feb 3, 2022 · 2 comments
Open

is this result correct? #38

sang0775 opened this issue Feb 3, 2022 · 2 comments

Comments

@sang0775
Copy link

sang0775 commented Feb 3, 2022

import Rotated_IoU.oriented_iou_loss as ri
import torch
import numpy as np
import math
box1 = torch.tensor([[[0.,0.,2.,2.,torch.pi/4]]]).to("cuda")
iou,_,_,_ = ri.cal_iou(box1, box1)
print(iou)

above iou value is "0."

but when i change box angle torch.pi/4 to torch.pi/4 + 0.01, it return 1.0 and this is what i expected.

@lilanxiao
Copy link
Owner

Hi, thank you for your issue. I cannot reproduce this problem. I get "1" on my machine.

Are you using the latest version of my code? I updated the CUDA extension to fix some bugs a long time ago. Please consider pulling the repo again and re-compile the CUDA extension.

@rubbish001
Copy link

最新版本的代码有问题,giou计算不准确

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