[ICLR 2024] Fine-tuning LLaMA to follow Instructions within 1 Hour and 1.2M Parameters
Geek Repo:Geek Repo
Github PK Tool:Github PK Tool
TeleeMa opened this issue 9 months ago · comments
Hi,
When I ran the forward function in
LLaMA-Adapter/llama_adapter_v2_multimodal7b/llama/llama_adapter.py
Line 151 in 95b6389
I printed out the dtype of the input and self.weight, self.bias , it showed the same dtype.
I solved the problem with the help of @csuhan . with torch.cuda.amp.autocast(): is also needed in the inference process if forward function is called, like in
with torch.cuda.amp.autocast():
LLaMA-Adapter/llama_adapter_v2_multimodal7b/engine_pretrain.py
Line 37 in 5e8c8b6
I will close the issue.