make round-to-grid with refinement the default, add --learned for learned rounding
On Qwen2.5-0.5B, learned rounding matched round-to-grid in perplexity and KL (22.38 vs 22.37, 0.0920 vs 0.0919) at about six times the quantize time. --simple is still accepted as a no-op. Docs and man pages updated. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
164fa6b4a4
commit
1e50e4e045
16 files changed
+76
-39
No files matched your search
@@ -19,7 +19,7 @@ safetensors_to_nvfp4_gguf \- quantize a safetensors file to an NVFP4 GGUF weight
|
||||
[\fB\-\-verbose\fR]
|
||||
[\fB\-\-self\-test\fR]
|
||||
[\fB\-\-device\fR \fIDEVICE\fR]
|
||||
[\fB\-\-simple\fR]
|
||||
[\fB\-\-learned\fR]
|
||||
[\fB\-\-optimizer\fR \fIOPT\fR]
|
||||
[\fB\-\-num\-iter\fR \fIN\fR]
|
||||
[\fB\-\-lr\fR \fILR\fR]
|
||||
@@ -93,8 +93,11 @@ Path to a vision projector GGUF to copy next to output. May be specified multipl
|
||||
Maximum context length to store in the GGUF metadata.
|
||||
.SS Quantization & Optimization
|
||||
.TP
|
||||
.B \-\-learned
|
||||
Use \fBconvert_to_quant\fR's learned rounding instead of the default round-to-grid with block-scale and code refinement. On Qwen2.5-0.5B it matched the default in perplexity and KL and took about six times as long.
|
||||
.TP
|
||||
.B \-\-simple
|
||||
Round each value directly onto the E2M1 grid without learned rounding.
|
||||
Round onto the E2M1 grid without learned rounding (default; accepted for compatibility).
|
||||
.TP
|
||||
.BI \-\-optimizer " " {auto,prodigy,adamw,radam,original}
|
||||
Learned-rounding optimizer (default: \fBauto\fR).
|
||||
@@ -199,10 +202,10 @@ safetensors_to_nvfp4_gguf --no-quant --outtype nvfp4 -o repacked.gguf comfy-nvfp
|
||||
.fi
|
||||
.RE
|
||||
.TP
|
||||
.B Quantize every eligible weight matrix with simple grid rounding:
|
||||
.B Quantize every eligible weight matrix (default grid rounding):
|
||||
.RS
|
||||
.nf
|
||||
safetensors_to_nvfp4_gguf --simple --all-weights -o fast-nvfp4.gguf model.safetensors
|
||||
safetensors_to_nvfp4_gguf --all-weights -o fast-nvfp4.gguf model.safetensors
|
||||
.fi
|
||||
.RE
|
||||
.SH EXIT STATUS
|
||||
|
||||
Reference in new issue
Block a user