Commit c1f0c25
[Transform] Serialize config (include format) (#420)
* add utilities
Signed-off-by: Kyle Sayers <[email protected]>
* add tests
Signed-off-by: Kyle Sayers <[email protected]>
* add additional tests
Signed-off-by: Kyle Sayers <[email protected]>
* add utils and tests
Signed-off-by: Kyle Sayers <[email protected]>
* Implement transform factories
Signed-off-by: Kyle Sayers <[email protected]>
* add permutations
Signed-off-by: Kyle Sayers <[email protected]>
* add delete_offload_module
Signed-off-by: Kyle Sayers <[email protected]>
* key inverses by weight
Signed-off-by: Kyle Sayers <[email protected]>
* fix tests
Signed-off-by: Kyle Sayers <[email protected]>
* standardize random hadamard
Signed-off-by: Kyle Sayers <[email protected]>
* prepend input hooks
Signed-off-by: Kyle Sayers <[email protected]>
* apply sqrt division first
Signed-off-by: Kyle Sayers <[email protected]>
* use divided hadamards
Signed-off-by: Kyle Sayers <[email protected]>
* fix typo
Signed-off-by: Kyle Sayers <[email protected]>
* add random option
Signed-off-by: Kyle Sayers <[email protected]>
* use random seeds, rename matrix multiply
Signed-off-by: Kyle Sayers <[email protected]>
* add deterministic generation to random matrix
Signed-off-by: Kyle Sayers <[email protected]>
* fix perm math
Signed-off-by: Kyle Sayers <[email protected]>
* update docstrings
Signed-off-by: Kyle Sayers <[email protected]>
* update docstrings
Signed-off-by: Kyle Sayers <[email protected]>
* cleanup
Signed-off-by: Kyle Sayers <[email protected]>
* cleanup 2
Signed-off-by: Kyle Sayers <[email protected]>
* make seed optional
Signed-off-by: Kyle Sayers <[email protected]>
* remove iterable check and missing return value
Signed-off-by: Kyle Sayers <[email protected]>
* Remove unrelated changes
* simplify code
Signed-off-by: Kyle Sayers <[email protected]>
* implement apply, use in tests
Signed-off-by: Kyle Sayers <[email protected]>
* use hadamards database file
Signed-off-by: Kyle Sayers <[email protected]>
* try manifest
Signed-off-by: Kyle Sayers <[email protected]>
* try setup, update hadamards list
Signed-off-by: Kyle Sayers <[email protected]>
* fix setup
Signed-off-by: Kyle Sayers <[email protected]>
* add docstrings, cleanup
Signed-off-by: Kyle Sayers <[email protected]>
* fix setup, thank you @dbarbuzzi
Signed-off-by: Kyle Sayers <[email protected]>
* remove numpy, add tests
Signed-off-by: Kyle Sayers <[email protected]>
* solidify dtype, add gpu tests
Signed-off-by: Kyle Sayers <[email protected]>
* fix docstring
Signed-off-by: Kyle Sayers <[email protected]>
* add device option
Signed-off-by: Kyle Sayers <[email protected]>
* construct on execution device, cache on offload device
Signed-off-by: Kyle Sayers <[email protected]>
* save construction device changes for later
Signed-off-by: Kyle Sayers <[email protected]>
* construct on execution device, cache on offload device
* cite nja sloane
Signed-off-by: Kyle Sayers <[email protected]>
* remove dreg
Signed-off-by: Kyle Sayers <[email protected]>
* put on device via safe_open
Signed-off-by: Kyle Sayers <[email protected]>
* nits and docstrings
Signed-off-by: Kyle Sayers <[email protected]>
* update docstring
Signed-off-by: Kyle Sayers <[email protected]>
* Merge
* merge with construct: construct in float32
Signed-off-by: Kyle Sayers <[email protected]>
* construct with same dtype, constructing on fp32 found no difference
Signed-off-by: Kyle Sayers <[email protected]>
* remove unnecessary imports
Signed-off-by: Kyle Sayers <[email protected]>
* bugfixes (#375)
Signed-off-by: Brian Dellabetta <[email protected]>
* use factory_kwargs
Signed-off-by: Kyle Sayers <[email protected]>
* add frozen dict to deps
Signed-off-by: Kyle Sayers <[email protected]>
* fix style
Signed-off-by: Kyle Sayers <[email protected]>
* merge
Signed-off-by: Kyle Sayers <[email protected]>
* use delete_offload_module
Signed-off-by: Kyle Sayers <[email protected]>
* add docstrign
Signed-off-by: Kyle Sayers <[email protected]>
* use parametrize
Signed-off-by: Kyle Sayers <[email protected]>
* populate _dynamic_tied_weights_keys
Signed-off-by: Kyle Sayers <[email protected]>
* ensure serializable
Signed-off-by: Kyle Sayers <[email protected]>
* remove extra space
Signed-off-by: Kyle Sayers <[email protected]>
* apply style
Signed-off-by: Kyle Sayers <[email protected]>
* merge dregs
* skip offloading tests until transformers changes land
Signed-off-by: Kyle Sayers <[email protected]>
* use set
Signed-off-by: Kyle Sayers <[email protected]>
* [Quantization][Decompression] Fix QDQ for dynamic quant; Update NVFP4 Compression Params (#407)
* add compression param; update qdq for batch greater than 1
* make generic
* fix tests
* remove incorrect line change; make generic
* update
* serialize
Signed-off-by: Kyle Sayers <[email protected]>
* fix typo, comment
Signed-off-by: Kyle Sayers <[email protected]>
* include format
Signed-off-by: Kyle Sayers <[email protected]>
---------
Signed-off-by: Kyle Sayers <[email protected]>
Signed-off-by: Brian Dellabetta <[email protected]>
Co-authored-by: Kyle Sayers <[email protected]>
Co-authored-by: Brian Dellabetta <[email protected]>1 parent 364472a commit c1f0c25
File tree
4 files changed
+69
-38
lines changed- src/compressed_tensors
- compressors/model_compressors
- transform
- factory
4 files changed
+69
-38
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | | - | |
18 | | - | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
19 | 21 | | |
20 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
Lines changed: 55 additions & 33 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| |||
43 | 44 | | |
44 | 45 | | |
45 | 46 | | |
| 47 | + | |
46 | 48 | | |
47 | 49 | | |
48 | 50 | | |
| |||
105 | 107 | | |
106 | 108 | | |
107 | 109 | | |
| 110 | + | |
108 | 111 | | |
109 | 112 | | |
110 | 113 | | |
| |||
144 | 147 | | |
145 | 148 | | |
146 | 149 | | |
| 150 | + | |
| 151 | + | |
147 | 152 | | |
148 | 153 | | |
149 | 154 | | |
| |||
177 | 182 | | |
178 | 183 | | |
179 | 184 | | |
| 185 | + | |
180 | 186 | | |
181 | 187 | | |
182 | 188 | | |
183 | 189 | | |
| 190 | + | |
184 | 191 | | |
185 | 192 | | |
186 | 193 | | |
187 | 194 | | |
188 | 195 | | |
189 | | - | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
190 | 200 | | |
191 | 201 | | |
192 | 202 | | |
193 | | - | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
194 | 206 | | |
195 | 207 | | |
196 | 208 | | |
| |||
254 | 266 | | |
255 | 267 | | |
256 | 268 | | |
| 269 | + | |
257 | 270 | | |
258 | 271 | | |
259 | 272 | | |
| 273 | + | |
| 274 | + | |
260 | 275 | | |
261 | 276 | | |
262 | 277 | | |
263 | 278 | | |
| 279 | + | |
264 | 280 | | |
265 | 281 | | |
266 | 282 | | |
| |||
640 | 656 | | |
641 | 657 | | |
642 | 658 | | |
643 | | - | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
644 | 664 | | |
645 | 665 | | |
| 666 | + | |
| 667 | + | |
646 | 668 | | |
647 | | - | |
648 | | - | |
649 | | - | |
650 | | - | |
651 | | - | |
652 | | - | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
653 | 674 | | |
654 | | - | |
655 | | - | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
| 678 | + | |
| 679 | + | |
| 680 | + | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
| 684 | + | |
| 685 | + | |
| 686 | + | |
| 687 | + | |
| 688 | + | |
| 689 | + | |
| 690 | + | |
656 | 691 | | |
657 | | - | |
658 | | - | |
659 | | - | |
660 | | - | |
661 | | - | |
662 | | - | |
663 | | - | |
664 | | - | |
665 | | - | |
666 | | - | |
667 | | - | |
668 | | - | |
669 | | - | |
670 | | - | |
671 | | - | |
672 | | - | |
673 | | - | |
674 | | - | |
675 | | - | |
676 | | - | |
677 | | - | |
678 | | - | |
| 692 | + | |
| 693 | + | |
| 694 | + | |
| 695 | + | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
679 | 700 | | |
| 701 | + | |
680 | 702 | | |
681 | 703 | | |
682 | 704 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
16 | 17 | | |
17 | 18 | | |
18 | 19 | | |
| |||
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | | - | |
| 17 | + | |
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
22 | 21 | | |
23 | 22 | | |
24 | 23 | | |
| |||
34 | 33 | | |
35 | 34 | | |
36 | 35 | | |
| 36 | + | |
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| |||
0 commit comments