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

when set inference_type=ar2, miss lr_imgs #21

Open
kidhan1234 opened this issue Jul 8, 2024 · 3 comments
Open

when set inference_type=ar2, miss lr_imgs #21

kidhan1234 opened this issue Jul 8, 2024 · 3 comments

Comments

@kidhan1234
Copy link

image
如题,当设置inference_type=ar2,cross_attention_forward()函数会报缺少lr_imgs,点进代码(model.py line 426)可以看到确实没有传递lr_imgs,奇怪的是选择full时没有这个bug,请问是什么原因呢
image

@xiaom233
Copy link

我也遇到了相同的问题,图比较大的时候full出现oom,ar1跑的比较慢,ar2存在bug不能使用

@yzy-thu
Copy link
Contributor

yzy-thu commented Aug 14, 2024

可以先把推理脚本里的cross_lr删掉跑下试试,我会尽快修一下这个bug

@Carl-Lin-cloud
Copy link

可以先把推理脚本里的cross_lr删掉跑下试试,我会尽快修一下这个bug

删掉了cross_lr跑的时候,只能单卡跑不能多卡并行。

(model.py line 718) output, *output_per_layers = self.model_forward(*args, hw=[vit_block_bsize,
vit_block_bsize],
mems=mems, inference=2, **kwargs)

手动添加了 lr_imgs=lr_imgs 依然跑不了,报错k must have shape (batch_size, seqlen_k, num_heads_k, head_size_og).

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

4 participants