metadata
license: apache-2.0
base_model:
- rhymes-ai/Aria-sequential_mlp
pipeline_tag: image-text-to-text
Aria-sequential_mlp-FP8-dynamic
FP8-Dynamic quant from rhymes-ai Aria made with llm-compressor.
Generated with the following code:
from transformers import AutoProcessor, AutoModelForCausalLM
from llmcompressor.modifiers.quantization import QuantizationModifier
from llmcompressor.transformers import SparseAutoModelForCausalLM, oneshot
model_name = "rhymes-ai/Aria-sequential_mlp"
model = SparseAutoModelForCausalLM.from_pretrained(model_name, device_map="auto", torch_dtype="auto", trust_remote_code=True)
processor = AutoProcessor.from_pretrained(model_name, trust_remote_code=True)
recipe = QuantizationModifier(
targets="Linear",
scheme="FP8_DYNAMIC",
ignore=["re:.*lm_head", "re:multi_modal_projector.*", "re:vision_tower.*"],
)
folder = model_name.split("/")[1] + "-FP8-Dynamic"
oneshot(model=model, recipe=recipe, output_dir=folder)
processor.save_pretrained(folder)