Commit d85ae22
Add LARS to str2optimizer32bit and fix error message (#1810)
LARS optimizer was missing from the str2optimizer32bit dispatch
dictionary, causing a ValueError on optimizer.step(). Map it to
momentum kernels (matching the LAMB→adam precedent). Also fix the
error message in _optimizer_update_32bit_impl which incorrectly
displayed str2optimizer8bit_blockwise keys instead of
str2optimizer32bit keys.
Add LARS to the parametrized 32-bit optimizer tests with
PytorchLARS as the reference implementation.
Fixes #1810
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent a2c92f7 commit d85ae22
2 files changed
+13
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
574 | 574 | | |
575 | 575 | | |
576 | 576 | | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
577 | 581 | | |
578 | 582 | | |
579 | 583 | | |
| |||
633 | 637 | | |
634 | 638 | | |
635 | 639 | | |
636 | | - | |
| 640 | + | |
637 | 641 | | |
638 | 642 | | |
639 | 643 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
105 | 110 | | |
106 | 111 | | |
107 | 112 | | |
| |||
118 | 123 | | |
119 | 124 | | |
120 | 125 | | |
| 126 | + | |
121 | 127 | | |
122 | 128 | | |
123 | 129 | | |
| |||
155 | 161 | | |
156 | 162 | | |
157 | 163 | | |
| 164 | + | |
158 | 165 | | |
159 | 166 | | |
160 | 167 | | |
| |||
181 | 188 | | |
182 | 189 | | |
183 | 190 | | |
184 | | - | |
| 191 | + | |
185 | 192 | | |
186 | 193 | | |
187 | 194 | | |
| |||
0 commit comments