-
Notifications
You must be signed in to change notification settings - Fork 59
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
Discriminative loss error: IndexError: Dimension out of range (expected to be in range of [-1, 0], but got 1) #13
Comments
I'm having the same problem. Reverting back to |
Hi, I am running your code, and I encountered the same problem. Have been there any updates after your last commit? |
I also tried both dim=0 and dim=1, both not working. |
Managed to fix it. It should be dim=1. The norm should be calculated along the "embedding" axis. Problem comes from embedding_i = embedding_b[seg_mask_i] which break the dims to get a single dimensional vector. Changing it to: works for me |
@mummy2358 Thank you. Will give it a try. |
@mummy2358 awesome thanks! Feel free to add a PR for the fix :) |
@mummy2358 I do not know why, on my side, after changing to |
May i knw where exactly the posotion of dim? |
hey @mengnutonomy, it happened to me also. I don't know if this does anything, but it seems you have to run 'python setup.py install' everytime you change your coding. Hope it'll work :) |
thx a lot ! rerun works for me |
|
Hi,
When running
python3 lanenet/train.py --dataset ./data/training_data_example
, I'm seeing the following exception:Any clues about how I can fix this? Not sure if I'm doing something incorrectly.
Thanks!
The text was updated successfully, but these errors were encountered: