bitsandbytes-cpu-fork 0.50.2.dev8__py3-none-win_amd64.whl → 0.50.2.dev9__py3-none-win_amd64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- bitsandbytes/__init__.py +1 -1
- bitsandbytes/libbitsandbytes_cpu.dll +0 -0
- bitsandbytes_cpu_cli.py +5 -5
- {bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/METADATA +9 -6
- {bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/RECORD +9 -9
- {bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/WHEEL +0 -0
- {bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/entry_points.txt +0 -0
- {bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/licenses/LICENSE +0 -0
- {bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/top_level.txt +0 -0
bitsandbytes/__init__.py
CHANGED
|
Binary file
|
bitsandbytes_cpu_cli.py
CHANGED
|
@@ -312,15 +312,15 @@ SECTIONS = [
|
|
|
312
312
|
"# what runs today is the verified scalar path",
|
|
313
313
|
"# the optimizer is a few percent of a real training step at 30M params,",
|
|
314
314
|
"# so the wall-clock cost is small while the state saving is 7.8x",
|
|
315
|
-
"# the pure-torch fallback (
|
|
315
|
+
"# older Windows wheels run the pure-torch fallback (dev9+ is native)",
|
|
316
316
|
], PY),
|
|
317
317
|
("traps",
|
|
318
318
|
"the failure modes seen while building this, each one silent at first", [
|
|
319
319
|
"# 1. torch.optim.AdamW is NOT replaced: this is a separate class, and",
|
|
320
320
|
"# AdamW4bit requires fp32 params (the kernel's dtype 0).",
|
|
321
321
|
"# 2. blocksize is compiled in at 256; passing another value raises.",
|
|
322
|
-
"# 3.
|
|
323
|
-
"# coptimizer_update_4bit_blockwise_cpu (
|
|
322
|
+
"# 3. older Windows wheels (< dev9) do not export",
|
|
323
|
+
"# coptimizer_update_4bit_blockwise_cpu (pre-dev9 Windows wheels),",
|
|
324
324
|
"# this class transparently uses a pure-torch implementation with the",
|
|
325
325
|
"# same numbers and the same 1.031 B/param state, just slower.",
|
|
326
326
|
"# 4. quantised state is not a drop-in for exact reproducibility runs:",
|
|
@@ -565,8 +565,8 @@ SECTIONS = [
|
|
|
565
565
|
("convert_linears_3bit(model, lora_r=8)",
|
|
566
566
|
"replaces every nn.Linear in place and returns the count; lm_head stays fp32", []),
|
|
567
567
|
("experimental / portability",
|
|
568
|
-
"the Windows wheel
|
|
569
|
-
"fallback
|
|
568
|
+
"since dev9 the Windows wheel ships a CI-built MSVC DLL; older wheels use the pure-torch "
|
|
569
|
+
"fallback, while the dev9 Windows and Linux wheels use the native kernels", []),
|
|
570
570
|
]),
|
|
571
571
|
("layers", "Reference: bitsandbytes.nn", [
|
|
572
572
|
("Linear4bit(input_features, output_features, bias=True, compute_dtype=None,\n"
|
{bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/METADATA
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: bitsandbytes-cpu-fork
|
|
3
|
-
Version: 0.50.2.
|
|
3
|
+
Version: 0.50.2.dev9
|
|
4
4
|
Summary: bitsandbytes with a pure-CPU training backend (AVX2 / NEON): 8-bit optimizers, fused GDN, gemm_8bit, disk balancer. No GPU required.
|
|
5
5
|
License-Expression: MIT
|
|
6
6
|
Project-URL: repository, https://github.com/Ganyvnanoaa09-0906/bitsandbytes-CPU
|
|
@@ -36,7 +36,7 @@ Dynamic: license-file
|
|
|
36
36
|
> toolkit and no driver** — just an AVX2 x86-64 CPU (or ARM64 NEON), the CPU build of PyTorch,
|
|
37
37
|
> and 12–16 GB of RAM.
|
|
38
38
|
|
|
39
|
-
**Version: `0.50.2.
|
|
39
|
+
**Version: `0.50.2.dev9`** · import name is unchanged (`import bitsandbytes as bnb`) · MIT.
|
|
40
40
|
|
|
41
41
|
What the CPU backend provides: 8-bit blockwise optimizers (≈2.3 bytes of state per parameter
|
|
42
42
|
instead of 8; the 4-bit optimizer ≈1.03), 4/8-bit layers that run on CPU tensors, the fused
|
|
@@ -202,7 +202,7 @@ Also: `estimate_training_memory_gb()`, `spawn_training_jobs(cmds, plan)` (logs p
|
|
|
202
202
|
| Area | What it does |
|
|
203
203
|
|---|---|
|
|
204
204
|
| 8-bit optimizers | AdamW/Adam/AdEMAMix/LAMB/LARS/Lion + paged variants, blockwise 8-bit state with single-pass dequant→update→requant kernels (AVX2/NEON) |
|
|
205
|
-
| 4-bit optimizer | `AdamW4bit`: ≈1.03 bytes of state per parameter (
|
|
205
|
+
| 4-bit optimizer | `AdamW4bit`: ≈1.03 bytes of state per parameter (scalar kernel; native on Linux and, since dev9, Windows) |
|
|
206
206
|
| Quantisation | blockwise 8-bit, NF4/FP4 4-bit quantize/dequantize; 4-bit GEMV inference kernel |
|
|
207
207
|
| `gemm_8bit` | `out = A @ dequant8(B)` with weights kept uint8 (¼ DRAM traffic), no fp32 temporary (`bnb.functional.fused_dequant_linear_8bit`) |
|
|
208
208
|
| GDN | fused Gated DeltaNet forward + chunk-checkpointed backward (`gdn_fwd_cpu` / `gdn_bwd_cpu`), plus `patch_transformers()` / `patch_fla()` |
|
|
@@ -256,6 +256,7 @@ R5-4500U (6C/6T, AVX2, 15.4 GB) / i5-10400 (6C/12T, AVX2, 12 GB), no NVIDIA GPU.
|
|
|
256
256
|
| Concurrency packing (synthetic jobs) | 6 jobs × 1 thread **5619 tok/s** vs 1 job × 6 threads **3843 tok/s** (+46%) |
|
|
257
257
|
| Real model (Qwen3.5-0.8B LoRA, seq 64) | 4 threads beat 6 by **7–10%** — measure with `tune_threads()` |
|
|
258
258
|
| Fused lm_head 3-bit GEMM (research) | 14–22% faster than fp32 matmul, 89% less weight memory |
|
|
259
|
+
| 3-bit frozen base + LoRA (Qwen3-1.7B, CPU) | 80 steps: eval loss 4.34 → **4.03**; RSS **2.9 GB vs 8.7 GB** fp32; step 7.7 s vs 5.5 s (native Windows) |
|
|
259
260
|
| AdamW4bit step (1M params) | 28.6 ms vs 3.3 ms for the AVX2 8-bit kernel; state 1.031 vs 2.062 B/param |
|
|
260
261
|
|
|
261
262
|
Not every workload is faster than fp32: 4-bit/8-bit kernels trade compute for memory traffic,
|
|
@@ -267,9 +268,10 @@ the full trade-off tables, including negative results.
|
|
|
267
268
|
## Platform limitations
|
|
268
269
|
|
|
269
270
|
- **CPU only.** CUDA/ROCm/XPU kernels are not built; a GPU is never required or used.
|
|
270
|
-
- **Windows wheel
|
|
271
|
-
|
|
272
|
-
|
|
271
|
+
- **Windows wheel**: from dev9 on it ships the MSVC DLL built by CI from the current
|
|
272
|
+
`csrc`, which exports the 2/3-bit dequant/GEMM and 4-bit optimizer kernels; they run
|
|
273
|
+
natively on Windows (verified: dequant maxdiff 1.2e-6, 4-bit native vs torch 1.2e-7).
|
|
274
|
+
Wheels older than dev9 fall back to pure torch for those symbols.
|
|
273
275
|
- **manylinux_2_17 wheel**: the AVX-512 library inside it is single-threaded (the parallel
|
|
274
276
|
build is only for the native `manylinux_2_39` wheel). On AVX-512 machines set
|
|
275
277
|
`BNB_CPU_DISABLE_AVX512=1` to run the AVX2 OpenMP path.
|
|
@@ -334,6 +336,7 @@ The long-form docs live in the repository (`bitsandbytes/docs_cpu/`, Chinese and
|
|
|
334
336
|
| `0.50.2.dev6` | manylinux_2_17 wheel is now **OpenMP** (devtoolset-8, bundled libgomp → 3–4× optimizer-kernel speedup on old glibc); csrc 2/3-bit dequant + fused GEMM kernels with 9-item C self-test; EFST fused tensor-expert routing fix; GCC 8 `<cpuid.h>` portability fix |
|
|
335
337
|
| `0.50.2.dev7` | documentation release: README rewritten for the CPU fork (install/wheels/platform matrix, feature table, measured performance, limitations, tests, full dev1→dev7 changelog, EFST/disk-balancer/toolbox examples) |
|
|
336
338
|
| `0.50.2.dev8` | **restored `AdamW4bit`** (the kernel was dropped when dev4 vendored upstream; now scalar C kernel + torch fallback, 1.031 B/param); **new `bitsandbytes.q3bit` API** — `quantize_3bit`/`dequantize_3bit`/`gemm_3bit`/`gemm_3bit_transposed`, `QuantLinear3bit` (frozen 3-bit base + LoRA), `convert_linears_3bit`, native kernels on Linux with identical pure-torch fallback; CLI reference now includes 4bitopt/q3bit and all 43 examples execute in CI-style verification |
|
|
339
|
+
| `0.50.2.dev9` | **Windows native kernels**: CI now compiles the MSVC DLL from the current csrc and the export list includes the 4-bit optimizer and 2/3-bit symbols (they were silently missing before); **q3bit real-model validation** on Qwen3-1.7B (frozen 3-bit base + LoRA, eval 4.34→4.03 over 80 steps, RSS −67%, native step 7.7 s vs fp32 5.5 s); fixed the causal-LM **double-shift** label bug in the iGPU training kit (Windows package v0.1.2) |
|
|
337
340
|
|
|
338
341
|
## License and attribution
|
|
339
342
|
|
{bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/RECORD
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
bitsandbytes_cpu_cli.py,sha256=
|
|
2
|
-
bitsandbytes/__init__.py,sha256
|
|
1
|
+
bitsandbytes_cpu_cli.py,sha256=xv4ZnPdkBZBeTXxOva6rAzfuUWbUrUKRDptL_UD8XWo,53297
|
|
2
|
+
bitsandbytes/__init__.py,sha256=hdEZe4A8_7bj_RALptP1Z1WwUBrAlCQjOR9wo253PmA,2514
|
|
3
3
|
bitsandbytes/__main__.py,sha256=A3iA9QH8yfn-60uN6w_7WUiuRIM777rZ_pf_HsZtse4,90
|
|
4
4
|
bitsandbytes/_cpu_caps.py,sha256=LgG3yRHdf0YGxTACxrweqiunghmuJbDAol4s02mwmHA,4691
|
|
5
5
|
bitsandbytes/_ops.py,sha256=VrOBIbain2ftHpBgxUHkf8fRpq1RCnsFi16tS-YGj6E,20640
|
|
@@ -12,7 +12,7 @@ bitsandbytes/disk_balancer.py,sha256=lyNgcqfBSsoflBDMffXKA4oNld4jBTbzugja988IN9w
|
|
|
12
12
|
bitsandbytes/efst.py,sha256=V3MGNwLicha2KmoFYmYM9RiEJCuU5Km8IsXDRWwXxXk,31222
|
|
13
13
|
bitsandbytes/functional.py,sha256=chLY-f592gXbSVOHA78ME3d-6Jq8rU3d2xJwx3GYDII,66814
|
|
14
14
|
bitsandbytes/gdn_cpu.py,sha256=QT5pdWwxPob6SL33wj4kjJLGnIkApivxvXjn7a--8Ys,27412
|
|
15
|
-
bitsandbytes/libbitsandbytes_cpu.dll,sha256=
|
|
15
|
+
bitsandbytes/libbitsandbytes_cpu.dll,sha256=O-Kn_gUodCynCOsd31mN9SWbgM7KpFiKS1EjJtkXrRo,403968
|
|
16
16
|
bitsandbytes/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
17
17
|
bitsandbytes/q3bit.py,sha256=6-xf6sreHj_Ks0XG6ELriFEjkWtKf_qfXfl4iywKLeo,21527
|
|
18
18
|
bitsandbytes/torch_cpu_kit.py,sha256=P5Bk5jI86sT3Z2cleWDwv9XV0ydZ2rPflNdxOP2zzPU,32844
|
|
@@ -58,9 +58,9 @@ bitsandbytes/optim/lion.py,sha256=OUu1aysIM85NNHNFu-LDTCLI6HoqPNMp-bLVgZAGtHk,83
|
|
|
58
58
|
bitsandbytes/optim/optimizer.py,sha256=LgegbqBzbk5s57uCEgcmSqXC5wRHGMiAIbe646Fd3y4,28127
|
|
59
59
|
bitsandbytes/optim/rmsprop.py,sha256=2sHSY1hfTr83aZvBmIEfzoTiKER8LZc_BDkmyJG3lPs,6134
|
|
60
60
|
bitsandbytes/optim/sgd.py,sha256=gVjbjjYrm197RiOt6vLoXaMxaWVK6De91Ap_KL6WFtg,4916
|
|
61
|
-
bitsandbytes_cpu_fork-0.50.2.
|
|
62
|
-
bitsandbytes_cpu_fork-0.50.2.
|
|
63
|
-
bitsandbytes_cpu_fork-0.50.2.
|
|
64
|
-
bitsandbytes_cpu_fork-0.50.2.
|
|
65
|
-
bitsandbytes_cpu_fork-0.50.2.
|
|
66
|
-
bitsandbytes_cpu_fork-0.50.2.
|
|
61
|
+
bitsandbytes_cpu_fork-0.50.2.dev9.dist-info/licenses/LICENSE,sha256=UkEte8fOQVfqYou6rLiCngqcs8WPV_mRdhJryM8r_IU,1086
|
|
62
|
+
bitsandbytes_cpu_fork-0.50.2.dev9.dist-info/METADATA,sha256=ItvSRA8PdiKE1Czcyp_iXWdmYYqKzVQuK-DyQDbU-8A,19045
|
|
63
|
+
bitsandbytes_cpu_fork-0.50.2.dev9.dist-info/WHEEL,sha256=5s7VO_HUPfjwcO4LINqxGe8JSFZAGgaurQKPGA4cx_g,97
|
|
64
|
+
bitsandbytes_cpu_fork-0.50.2.dev9.dist-info/entry_points.txt,sha256=GqLu5Rm-j-9_CvhqX0jVecyJShA1XGmxRoPEiibJpcI,99
|
|
65
|
+
bitsandbytes_cpu_fork-0.50.2.dev9.dist-info/top_level.txt,sha256=l9ip7vjQq1JV6CB_ZGntWtjfxpkH119NDxupnJho9k0,34
|
|
66
|
+
bitsandbytes_cpu_fork-0.50.2.dev9.dist-info/RECORD,,
|
{bitsandbytes_cpu_fork-0.50.2.dev8.dist-info → bitsandbytes_cpu_fork-0.50.2.dev9.dist-info}/WHEEL
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|