Downloads · 30 days
26
3% of all-time downloads
JongYeop/Qwen2.5-7B-Instruct-FP4-W4A4
Qwen2.5-7B-Instruct-FP4-W4A4 is a text generation model from JongYeop. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
This is an NVFP4 (NVIDIA FP4) quantized version of Qwen/Qwen2.5-7B-Instruct using the compressed-tensors quantization method.
Downloads · 30 days
26
3% of all-time downloads
All-time downloads
913
Public
Parameters
4.8B
5.9 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors5.9 GB · 100%
How the weights are stored.
U83.3B · 69%
From the Hugging Face model README
This is an NVFP4 (NVIDIA FP4) quantized version of Qwen/Qwen2.5-7B-Instruct using the compressed-tensors quantization method.
This model uses NVFP4 (NVIDIA FP4) quantization with grouped quantization for both weights and activations:
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "JongYeop/Qwen2.5-7B-Instruct-FP4-W4A4"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
device_map="auto",
torch_dtype="auto"
)
messages = [
{"role": "user", "content": "What is machine learning?"}
]
input_ids = tokenizer.apply_chat_template(
messages,
add_generation_prompt=True,
return_tensors="pt"
).to(model.device)
outputs = model.generate(
input_ids,
max_new_tokens=256,
do_sample=True,
temperature=0.7,
top_p=0.9,
)
response = tokenizer.decode(outputs[0][input_ids.shape[-1]:], skip_special_tokens=True)
print(response)
This quantized model is intended for efficient inference with significantly reduced memory footprint while maintaining reasonable performance. It is suitable for:
If you use this model, please cite the original Qwen2.5 paper and the compressed-tensors library.
Same as the base model: Apache 2.0