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

Add NPU support for Llava #1446

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

HelloWorldBeginner
Copy link

[NPU] Support Llava training and inference for Ascend NPU.

I've modified some codes to add support for NPU, allowing LLAVA to perform both training and inference on NPU.
It works fine on NPU.
NPU Training
image
NPU Evaluate
image
NPU Inference
image

@HelloWorldBeginner
Copy link
Author

HelloWorldBeginner commented May 6, 2024

Hi @haotian-liu
Can you review my codes?

@MengqingCao
Copy link

cool! It helps for NPU users like me, thx!

@xslasd
Copy link

xslasd commented May 23, 2024

非常棒,我运行起来了

@zmf2022
Copy link

zmf2022 commented May 27, 2024

when I run this code,RuntimeError: "slow_conv2d_cpu" not implemented for 'Half'

@ReyRen
Copy link

ReyRen commented Jun 4, 2024

size mismatch for O.weight: copying a param with shape torch.Size ([4096, 1024]) from checkpoint, the shape in current model is torch.!
size mismatch for O. bias: copying a param with shape torch.Size ( [4096]) from checkpoint, the shape in current model is torch.Size ([0]
size mismatch for 2.weight: copying a param with shape torch.Size([4096, 4096]) from checkpoint, the shape in current model is torch.
size mismatch for 2.bias: copying a param with shape torch.Size ([40961) from checkpoint,
the shape in current model is torch.Size([0].

@HelloWorldBeginner When I run with thses commits, the error occured like above. Can you please give me some hints? thx

@ReyRen
Copy link

ReyRen commented Jun 13, 2024

I get "RuntimeError: The size of tensor a (32) must match the size of tensor b (1258) at non-singleton dimension 3" error, need help, please.

@Yangr116
Copy link

Yangr116 commented Aug 5, 2024

Can you reproduce the results using NPU? @HelloWorldBeginner

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

Successfully merging this pull request may close these issues.

6 participants