LocateAnything-3B-mlx-8bit

8-bit MLX conversion of nvidia/LocateAnything-3B optimized for Apple Silicon native GPU inference.

Converted by: SirSahOl
Source Model: nvidia/LocateAnything-3B
Framework: MLX by Apple
Quantization: 8-bit (Average 8.25 bits per weight)
Format: safetensors
License: other


Model Details

  • Architecture: LocateAnythingForConditionalGeneration

  • Parameters: 3B

  • Context Length: 32,768 tokens

  • Format: MLX (Apple Silicon native GPU format)

  • Quantization: 8-bit (Average 8.25 bits per weight)

  • Active VRAM Footprint: ~3.7 GB (Minimum recommended: 8 GB Unified Memory)

  • Mixed Precision Strategy: Language backbone: 8-bit affine; Vision encoder: BF16 unquantized (maintains sub-pixel coordinate alignment for visual grounding)

  • Coordinate Output Format: Normalized [ymin, xmin, ymax, xmax] in [0, 1000] range


Quick Start

Installation

pip install mlx-vlm

Usage

CLI

# Generate visual grounding completion
python -m mlx_vlm.generate --model SirSahOl/LocateAnything-3B-mlx-8bit --image screenshot.png --prompt "locate: submit button"

Python API (LocateAnything / Visual Grounding)

from mlx_vlm import load, generate
from mlx_vlm.utils import load_image

# Load model natively onto Apple Silicon GPU (Metal)
model, processor = load("SirSahOl/LocateAnything-3B-mlx-8bit")

prompt = "locate: submit button"
image_path = "screenshot.png"

# Format messages using the Qwen/LocateAnything vision template
messages = [
    {
        "role": "user",
        "content": [
            {"type": "image"},
            {"type": "text", "text": prompt}
        ]
    }
]
formatted_prompt = processor.apply_chat_template(messages, add_generation_prompt=True)

# Generate bounding box coordinates [ymin, xmin, ymax, xmax] normalized 0-1000
result = generate(model, processor, prompt=formatted_prompt, image=image_path, verbose=False)
print("Detected bounding box:", result.text)

Performance Benchmarks

Measured Benchmarks (Apple M1)

Metric 8-bit
Tokens/sec 25.0
TTFT 150.0 ms
Peak Memory 167.0 MB

Benchmarked on Apple M1 with 8GB unified memory. Average over 5 runs with 20 max tokens.


Multi-Quantization Comparison

Evaluate your hardware budget and choose the optimal precision:

Variant Disk Size VRAM Footprint Target Apple Silicon Hardware Key Advantage
4-bit MLX ~2.0 GB ~2.0 GB M1 / M2 / M3 / M4 (8GB+) Maximum generation speed and lowest RAM overhead.
8-bit MLX (This Repository) ~3.6 GB ~3.6 GB M1 / M2 / M3 / M4 Pro/Max (16GB+) Balanced accuracy and generation speed; near-lossless reasoning.
16-bit MLX ~6.8 GB ~6.8 GB M2 / M3 / M4 Max/Ultra (32GB+) Full unquantized precision; reference evaluation quality.

Who Should Use This?

Your Hardware Recommended Quantization
M1/M2/M3/M4 (8GB – 16GB) 4-bit β€” Best balance of speed, low memory, and multitasking capability
M1/M2/M3/M4 Pro/Max (18GB – 36GB) 8-bit β€” Higher quality reasoning with comfortable memory headroom
M1/M2/M3/M4 Max/Ultra (36GB – 192GB) 16-bit β€” Unquantized full precision, zero quality degradation

General guidance:

  • Use 4-bit if you want to run this model alongside IDEs, browsers, and background development tools.
  • Use 8-bit if you have 16GB+ unified memory and require superior reasoning and code accuracy.
  • Use 16-bit for research, benchmarking, evaluation, or high-end workstation deployments.

Other Quantization Variants


LM Studio & Local Inference Setup Guide

To prevent runaway loops and ensure correct conversational turn-taking, configure custom stop tokens in your local inference runtime:

  1. <|im_start|>
  2. <|im_end|>
  3. <|endoftext|>

Prompt Template Formatting

  • System Prefix: <|im_start|>system\n
  • System Suffix: <|im_end|>\n
  • User Prefix: <|im_start|>user\n
  • Assistant Suffix: <|im_end|>\n<|im_start|>assistant\n

Ollama Quickstart

FROM SirSahOl/LocateAnything-3B-mlx-8bit
PARAMETER stop "<|im_start|>"
PARAMETER stop "<|im_end|>"
PARAMETER stop "<|endoftext|>"
PARAMETER temperature 0.7
ollama create locateanything-3b-mlx-8bit -f Modelfile
ollama run locateanything-3b-mlx-8bit

Conversion Details

Property Value
Source Model nvidia/LocateAnything-3B
Quantization 8-bit
mlx-lm Version N/A
Conversion Time 71.73s
Output Size 3.9 GB
Date 2026-10-14T09:16:57.736156+00:00

Reproduction

To reproduce this conversion:

pip install mlx-lm==latest
python3 -m mlx_vlm convert --hf-path nvidia/LocateAnything-3B --mlx-path output/LocateAnything-3B-mlx-8bit --trust-remote-code -q --q-bits 8 --q-group-size 64

Limitations & Known Issues

  • 4-bit group-wise quantization introduces minor precision loss compared to unquantized weights; for deep mathematical derivations or precision-critical reasoning, test the 8-bit or 16-bit variants.
  • High context sequences (>32K tokens) require sufficient unified memory headroom; ensure unified memory is not overcommitted.
  • This is a weight-only MLX conversion designed specifically for Apple Silicon GPUs (M1/M2/M3/M4 series).

License

This model conversion inherits the license of the source model: other.

See the original model card for full license details.


Changelog

Version Date Changes
v1.0 2026-10-14 Initial conversion

Converted with MLX Foundry β€” a professional pipeline for converting models to Apple MLX format.

Downloads last month
162
Safetensors
Model size
4B params
Tensor type
U32
Β·
BF16
Β·
MLX
Hardware compatibility
Log In to add your hardware

8-bit

Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for SirSahOl/LocateAnything-3B-mlx-8bit

Base model

Qwen/Qwen2.5-3B
Quantized
(26)
this model

Space using SirSahOl/LocateAnything-3B-mlx-8bit 1

Collection including SirSahOl/LocateAnything-3B-mlx-8bit