Commit 1480d81
committed
chore: make weight override more robust against ggml changes
Recently, GGML_TYPE_COUNT got bumped for the new GGML_TYPE_MXFP4
quant, getting it out-of-sync with SD_TYPE_COUNT.
To make it easier to build stable-diffusion.cpp against different
ggml versions when other weight types get added to ggml, adjust
the type conversions to consider both GGML_TYPE_COUNT and
SD_TYPE_COUNT as limits.1 parent fce6afc commit 1480d81
2 files changed
+9
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2310 | 2310 | | |
2311 | 2311 | | |
2312 | 2312 | | |
2313 | | - | |
| 2313 | + | |
2314 | 2314 | | |
2315 | 2315 | | |
2316 | 2316 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
265 | 265 | | |
266 | 266 | | |
267 | 267 | | |
268 | | - | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
269 | 271 | | |
270 | 272 | | |
271 | 273 | | |
| |||
1467 | 1469 | | |
1468 | 1470 | | |
1469 | 1471 | | |
1470 | | - | |
| 1472 | + | |
| 1473 | + | |
| 1474 | + | |
| 1475 | + | |
1471 | 1476 | | |
1472 | 1477 | | |
1473 | 1478 | | |
1474 | | - | |
| 1479 | + | |
1475 | 1480 | | |
1476 | 1481 | | |
1477 | 1482 | | |
| |||
0 commit comments