mirror of
https://github.com/ROCm/composable_kernel.git
synced 2026-06-29 03:07:02 +00:00
[CK dispatcher] - LGBM predict data_type FLOAT32->FLOAT64 in ml_heuristic (#8132) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ## Summary `ml_heuristic.hpp` calls `LGBM_BoosterPredictForMat(..., /*data_type=*/0, ...)` (`C_API_DTYPE_FLOAT32`) against a `std::array<double, NUM_FEATURES>` feature buffer. LightGBM reinterprets the 8-byte doubles as 4-byte floats → invalid predictions → the heuristic's argmax always tie-breaks to the first/smallest enumerated config. **Fix:** `data_type 0 → 1` (`C_API_DTYPE_FLOAT64`), matching the `double` buffer. After the fix, predictions vary and track real TFLOPS (the model correctly prefers larger tiles). ## Verification - The feature buffer `f` is `std::array<double, NUM_FEATURES>` (NUM_FEATURES = 72) → `f.data()` is a `double*`. - The changed `0` is the 3rd positional `data_type` argument (not `nrow`/`ncol`/`is_row_major`). One-line functional change. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>