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

IndexError: tensors used as indices must be long, byte or bool tensors #12

Open
Peter-jj opened this issue Jul 11, 2023 · 1 comment
Open

Comments

@Peter-jj
Copy link

when I run the resume_solider.sh,it maybe traceback with
File "main_solider.py", line 398, in train_one_epoch
semantic_weight = [torch.cat(semantic_weight)[torch.from_numpy(mask_idxs)]]
IndexError: tensors used as indices must be long, byte or bool tensors
how can I deal with it

@debenton
Copy link

debenton commented Nov 5, 2023

Hi authors - the code is not finetunable when mask_ids is empty - can you give a pointer on what to do? I tried indenting that line and got a tensor size mismatch error (16 vs. 8).

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