🚀 SpaceLLaVA
SpaceLLaVA 是一款多模態的視覺語言模型,它基於LLaVA - 1.5(13B)進行適配,並通過LoRA微調以增強空間推理能力。該模型使用合成VQA數據集進行訓練,在定性和定量空間推理方面表現出色。
🚀 快速開始
GGUF
使用此筆記本,藉助llama - cpp - python查詢場景中對象之間的空間關係。

Docker
docker build -f Dockerfile -t spacellava-server:latest
docker run -it --rm --gpus all -p8000:8000 -p8001:8001 -p8002:8002 --shm-size 12G spacellava-server:latest
python3 client.py --image_path "https://remyx.ai/assets/spatialvlm/warehouse_rgb.jpg" --prompt "What is the distance between the man in the red hat and the pallet of boxes?"
✨ 主要特性
- 多模態能力:作為視覺語言模型,能夠處理圖像和文本信息。
- 強大的空間推理:經過微調,在定性和定量空間推理方面表現出色。
- 基於成熟架構:基於
llava - v1.5 - 13b
架構,具有13.4B參數(FP16)。
📦 安裝指南
Docker安裝
docker build -f Dockerfile -t spacellava-server:latest
Docker運行
docker run -it --rm --gpus all -p8000:8000 -p8001:8001 -p8002:8002 --shm-size 12G spacellava-server:latest
客戶端調用
python3 client.py --image_path "https://remyx.ai/assets/spatialvlm/warehouse_rgb.jpg" --prompt "What is the distance between the man in the red hat and the pallet of boxes?"
📚 詳細文檔
模型信息
屬性 |
詳情 |
模型類型 |
多模態,視覺語言模型 |
架構 |
llava - v1.5 - 13b |
模型大小 |
13.4B參數(FP16) |
微調基礎 |
liuhaotian/llava - v1.5 - 13b |
微調策略 |
LoRA(低秩自適應) |
許可證 |
Apache - 2.0 |
數據集與訓練
數據集包含約28,000個合成樣本,使用模板化的VQA對和3D場景重建管道創建。數據格式包括圖像(RGB)、問題(文本)和答案(文本),空間關係類型包括“距離”、“大小”、“在……左邊”、“在……上方”、“更靠近”、“在……裡面”等。
LoRA SFT腳本可在 trl 找到。查看 [SpaceVLMs集合](https://huggingface.co/collections/remyxai/spacevlms - 66a3dbb924756d98e7aec678)。
模型評估(即將推出)
計劃使用VLMEvalKit在QSpatial基準、VSR等上進行評估。
試用
可在Discord上試用:http://discord.gg/b2yGuCNpuC
🔧 技術細節
SpaceLLaVA從 VQASynth 的管道中提煉3D場景理解,從而在空間推理方面表現出強大的能力。它基於LLaVA - 1.5(13B)進行微調,採用LoRA(低秩自適應)策略,在合成VQA數據集上進行訓練,該數據集受 [SpatialVLM](https://spatial - vlm.github.io/) 方法的啟發。
⚠️ 限制與倫理考慮
⚠️ 重要提示
- 模型在雜亂環境或特定相機視角下性能可能下降。
- 該模型使用合成推理在互聯網圖像數據集上進行微調。
- 基礎模型(LLaVA)固有的多模態偏差可能仍然存在。
- 不建議用於安全關鍵或法律決策場景。
💡 使用建議
鼓勵用戶批判性地評估模型輸出,並考慮針對特定領域進行微調以提高安全性和性能。
📄 許可證
本項目採用Apache - 2.0許可證。
@article{chen2024spatialvlm,
title = {SpatialVLM: Endowing Vision-Language Models with Spatial Reasoning Capabilities},
author = {Chen, Boyuan and Xu, Zhuo and Kirmani, Sean and Ichter, Brian and Driess, Danny and Florence, Pete and Sadigh, Dorsa and Guibas, Leonidas and Xia, Fei},
journal = {arXiv preprint arXiv:2401.12168},
year = {2024},
url = {https://arxiv.org/abs/2401.12168},
}
@misc{liu2023llava,
title={Visual Instruction Tuning},
author={Liu, Haotian and Li, Chunyuan and Wu, Qingyang and Lee, Yong Jae},
publisher={NeurIPS},
year={2023},
}