LLaVA icon indicating copy to clipboard operation
LLaVA copied to clipboard

Add NPU support for Llava

Open HelloWorldBeginner opened this issue 10 months ago • 7 comments

[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 avatar Apr 23 '24 09:04 HelloWorldBeginner

Hi @haotian-liu Can you review my codes?

HelloWorldBeginner avatar May 06 '24 03:05 HelloWorldBeginner

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

MengqingCao avatar May 08 '24 01:05 MengqingCao

非常棒,我运行起来了

xslasd avatar May 23 '24 10:05 xslasd

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

zmf2022 avatar May 27 '24 08:05 zmf2022

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 avatar Jun 04 '24 04:06 ReyRen

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.

ReyRen avatar Jun 13 '24 09:06 ReyRen

Can you reproduce the results using NPU? @HelloWorldBeginner

Yangr116 avatar Aug 05 '24 03:08 Yangr116