Skip to content

Instantly share code, notes, and snippets.

@cijlabs
cijlabs / expert_weight_analysis.py
Created April 4, 2026 09:24
ABIS-Quant Expert Weight Analysis
#!/usr/bin/env python3
"""
ABIS-Quant: Expert Weight Sensitivity Analysis
================================================
Analyzes per-expert weight statistics to determine quantization sensitivity.
Streams tensors directly from HuggingFace — no local model copy needed.
Outputs expert_precision_map.json with real per-expert precision assignments.
Metrics per expert: