Downloads · 30 days
598
7% of all-time downloads
wangkanai/qwen2.5-vl-7b-instruct
qwen2.5-vl-7b-instruct is a image-text-to-text model from wangkanai. Use it for the image-text-to-text task on the model card, and read the license before you ship it in a product. It is set up for transformers. The card lists the license as apache-2.0.
Qwen2.5-VL-7B-Instruct is a vision-language model from the Qwen 2.5 family, designed for multimodal understanding and generation tasks. This is an abliterated version with safety filters reduced or removed, providing…
Downloads · 30 days
598
7% of all-time downloads
All-time downloads
8.7K
Public
Repo size
42 GB
Likes
5
Public
Click a slice to open those files.
.gguf25.4 GB · 60%
From the Hugging Face model README
Qwen2.5-VL-7B-Instruct is a vision-language model from the Qwen 2.5 family, designed for multimodal understanding and generation tasks. This is an abliterated version with safety filters reduced or removed, providing more direct responses. The 7-billion parameter model can process both images and text, making it suitable for visual question answering, image captioning, and multimodal conversational AI.
Qwen2.5-VL-7B-Instruct is an instruction-tuned multimodal large language model that combines:
qwen2.5-vl-7b-instruct/
├── qwen2.5-vl-7b-instruct-abliterated.safetensors # 16GB (FP16 SafeTensors)
├── qwen2.5-vl-7b-instruct-abliterated-f16.gguf # 15GB (FP16 GGUF)
├── qwen2.5-vl-7b-instruct-abliterated-q5-k-m.gguf # 5.1GB (Q5_K_M quantized)
└── qwen2.5-vl-7b-instruct-abliterated-q4-k-m.gguf # 4.4GB (Q4_K_M quantized)
Total Repository Size: ~40GB
| Format | VRAM Required | Disk Space | Recommended GPU |
|---|---|---|---|
| FP16 SafeTensors | ~16-18GB | 16GB | RTX 4090, A100, A6000 |
| FP16 GGUF | ~15-16GB | 15GB | RTX 4090, A100, A6000 |
| Q5_K_M GGUF | ~6-7GB | 5.1GB | RTX 3090, RTX 4070 Ti, V100 |
| Q4_K_M GGUF | ~5-6GB | 4.4GB | RTX 3060 12GB, RTX 4060 Ti |
System Requirements:
from transformers import Qwen2VLForConditionalGeneration, AutoProcessor
from PIL import Image
import torch
# Load model and processor
model_path = "E:/huggingface/qwen2.5-vl-7b-instruct"
model = Qwen2VLForConditionalGeneration.from_pretrained(
model_path,
torch_dtype=torch.float16,
device_map="auto"
)
processor = AutoProcessor.from_pretrained("Qwen/Qwen2.5-VL-7B-Instruct")
# Load and process image
image = Image.open("your_image.jpg")
prompt = "Describe this image in detail."
# Prepare inputs
inputs = processor(
text=prompt,
images=image,
return_tensors="pt"
).to("cuda")
# Generate response
output = model.generate(
**inputs,
max_new_tokens=512,
temperature=0.7,
do_sample=True
)
# Decode response
response = processor.decode(output[0], skip_special_tokens=True)
print(response)
# Q4_K_M quantized version (most efficient)
llama-cli \
--model "E:/huggingface/qwen2.5-vl-7b-instruct/qwen2.5-vl-7b-instruct-abliterated-q4-k-m.gguf" \
--image "your_image.jpg" \
--prompt "What do you see in this image?" \
--ctx-size 4096 \
--n-gpu-layers 35 \
--temp 0.7
# Q5_K_M quantized version (better quality)
llama-cli \
--model "E:/huggingface/qwen2.5-vl-7b-instruct/qwen2.5-vl-7b-instruct-abliterated-q5-k-m.gguf" \
--image "your_image.jpg" \
--prompt "Analyze the objects and their relationships in this image." \
--ctx-size 4096 \
--n-gpu-layers 35 \
--temp 0.7
# Create Modelfile
cat > Modelfile <<EOF
FROM E:/huggingface/qwen2.5-vl-7b-instruct/qwen2.5-vl-7b-instruct-abliterated-q4-k-m.gguf
PARAMETER temperature 0.7
PARAMETER top_p 0.9
EOF
# Import model
ollama create qwen2.5-vl-abliterated -f Modelfile
# Use the model
ollama run qwen2.5-vl-abliterated "Describe this image" --image your_image.jpg
| Specification | Details |
|---|---|
| Architecture | Qwen2.5-VL (Vision-Language Transformer) |
| Parameters | 7 billion |
| Context Length | 4096 tokens (text + image) |
| Vision Encoder | ViT-based image encoder |
| Precision | FP16 (full), Q5_K_M, Q4_K_M (quantized) |
| Formats | SafeTensors, GGUF |
| Modification | Abliterated (safety filters reduced) |
| Input Types | Text + Images (JPEG, PNG, WebP) |
| Output Type | Text (natural language) |
--n-gpu-layers parameter to maximize GPU utilization# Enable memory-efficient attention
model = Qwen2VLForConditionalGeneration.from_pretrained(
model_path,
torch_dtype=torch.float16,
device_map="auto",
use_flash_attention_2=True, # Requires flash-attn installed
low_cpu_mem_usage=True
)
from PIL import Image
# Resize large images to reduce memory usage
def preprocess_image(image_path, max_size=1024):
image = Image.open(image_path)
image.thumbnail((max_size, max_size), Image.LANCZOS)
return image
⚠️ Important: This is an abliterated model variant with reduced safety restrictions. Key considerations:
This model is licensed under Apache 2.0, allowing both commercial and non-commercial use with attribution.
See the Apache 2.0 license for full terms: https://www.apache.org/licenses/LICENSE-2.0
If you use this model in your research or applications, please cite:
@article{qwen2.5-vl,
title={Qwen2.5-VL: A Vision-Language Model with Enhanced Capabilities},
author={Qwen Team},
journal={arXiv preprint},
year={2024},
url={https://huggingface.co/Qwen/Qwen2.5-VL-7B-Instruct}
}
For technical issues or questions:
Model Format: SafeTensors + GGUF | Precision: FP16, Q5_K_M, Q4_K_M | Size: 4.4GB - 16GB