import torchfrom transformers import AutoModelForImageTextToText, AutoProcessorfrom peft import PeftModel base = "Qwen/Qwen3-VL-8B-Instruct"model = AutoModelForImageTextToText.from_pretrained(base, dtype=torch.bfloat16, device_map="cuda")model = PeftModel.from_pretrained(model, "EasonFan/aircop-8b")processor = AutoProcessor.from_pretrained(base) messages = [{"role": "user", "content": [ {"type": "text", "text": "UAV1:"}, {"type": "image"}, {"type": "text", "text": "UAV2:"}, {"type": "image"}, {"type": "text", "text": "Question: ...\nOptions:\nA. ...\nB. ...\nC. ...\nD. ...\nAnswer with only the letter."},]}]# build inputs with processor.apply_chat_template + processor(...) and call model.generate()