Replies: 1 comment
-
|
Vision LoRA with vLLM is tricky — the vision encoder and language model have different requirements. The issue:
Workarounds: 1. Two-stage merge # Merge text LoRA first
text_merged = model.merge_and_unload(text_lora)
# Then merge vision separately
full_merged = merge_vision_adapter(text_merged, vision_lora)2. Serve without fast_inference model = FastModel.from_pretrained(
base_model,
fast_inference=False, # Slower but works with unmerged
vision_lora=vision_adapter_path,
text_lora=text_adapter_path
)3. Export to separate checkpoints
Root cause: vLLM's adapter loading assumes single LoRA, not multimodal splits. We've deployed VLMs with LoRA at RevolutionAI. The full merge approach is most reliable for production. What's your serving setup — vLLM directly or through another layer? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
I am currently moving from SFT to Reinforcement Learning (GRPO) on Qwen3-VL-8B-Instruct using Unsloth. I have a specific constraint regarding vLLM compatibility and Vision LoRAs.
I successfully performed SFT using
16bit LoRAwith vision layers enabled.Here is my SFT configuration:
I am now initializing the GRPO trainer starting from my best SFT checkpoint (
step-175). I want to leverage vLLM (fast_inference=True) to speed up the generation phase of GRPO.I understand that vLLM does not currently support LoRA for vision/encoder layers. However, since I finetuned those layers during SFT, they are part of my adapter.
I explicitly do not want to merge the LoRA adapter into the base model yet, as I have observed precision discrepancies after merging.
My Questions:
fast_inference=Truewith my current checkpoint, will vLLM simply ignore the vision weights in the adapter (and fallback to base vision weights), or will it crash?Any guidance on how to configure the
PeftModelor Unsloth for this specific scenario would be greatly appreciated.Thanks!
Beta Was this translation helpful? Give feedback.
All reactions