-
Notifications
You must be signed in to change notification settings - Fork 66
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 doubt about "Line 97: priors = priors[pos_idx].view(-1, 4)" in multibox_loss.py #1
Comments
@AllenMao I am confused with that problem,too. It works well because both of 'priors' and 'pos_idx' are Variable. If they are tensor, it will fail to run success. |
@huangzsdy: I got the same problem not because they are tensor. It is because of dimensions are not appropriate. For example when running on PASCAL Thank you |
@huangzsdy i used pytoch-0.3.1. |
@lthngan My environment is Python 3.6.2 :: Anaconda custom (64-bit), pytorch0.3.1.post2. It works well. but if they are Variable, it works well However, It failed when i used pytorch0.4.0(python3.6.2). It came out this error,'IndexError: too many indices for tensor of dimension 2'. The above is just what I found through the experiment. I am confused with this problem,too. If you figure it out, pls let me know...thx. |
@AllenMao What's your python version ? What 's your error message ? |
@huangzsdy the same as you. My environment is python3.5.5 and pytorch0.3.1 if use 'priors = priors.expand_as(pos_idx)' or pytorch-0.4.0, it came out error in later. so i use pytoch-0.3.1 and run well. |
I think I've found a solution, and it works. |
hi, i have a doubt, such as the title. the shape of priors is (num_priors, 4), and pos_idx is (num, num_priors, 4). this code how to run success? thank u!
The text was updated successfully, but these errors were encountered: