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

Input shape RuntimeError #12

Open
iamamiramine opened this issue Dec 4, 2023 · 1 comment
Open

Input shape RuntimeError #12

iamamiramine opened this issue Dec 4, 2023 · 1 comment

Comments

@iamamiramine
Copy link

I am getting the following error when i'm trying to train
RuntimeError: shape '[1, 125584, 32]' is invalid for input of size 8037376

It is coming from this method
tgt2 = self.multihead_attn(query=self.with_pos_embed(tgt, query_pos), key=self.with_pos_embed(memory, pos), value=memory, attn_mask=memory_mask, key_padding_mask=memory_key_padding_mask)[0]
in src/models/transformer/deformable_transformer.py

Any idea why?

@cxylotus
Copy link

I have met the similar error with you, after I modified the get_ref_imgs function in vid_multi.py, the error is gone.
In my view, it's the self.frame_seg_len[idx] out of idex, I hope this can help you.

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