visual-openllm/visual-openllm-chatglm-6b-rola
9
1---2license: apache-2.03datasets:4- tatsu-lab/alpaca5- shibing624/alpaca-zh6---7 8- Loda LLM9 10```python11from modeling_chatglm import ChatGLMForConditionalGeneration12import torch13 14 15torch.set_default_tensor_type(torch.cuda.HalfTensor)16model = ChatGLMForConditionalGeneration.from_pretrained("THUDM/chatglm-6b", trust_remote_code=True, device_map='auto')17```18 19- Load LoRA20 21```python22from peft import PeftModel23 24model = PeftModel.from_pretrained(model, "visual-openllm/visual-openllm-chatglm-6b-rola")25torch.set_default_tensor_type(torch.cuda.FloatTensor)26```