triton-lang / triton

Development repository for the Triton language and compiler
https://triton-lang.org/
MIT License
11.91k stars 1.41k forks source link

Get autotune configs #3843

Open Luke20000429 opened 2 months ago

Luke20000429 commented 2 months ago

The autotune feature is great but takes time in the first several rounds. How to get the dictionary of autotune results after running a few cycles? In that way, I can hardcode the config choice in the release version.

ThomasRaoux commented 2 months ago

you can set env var: TRITON_PRINT_AUTOTUNING=1 or you can also do print(kernl.best_config) after running auto tuning

Luke20000429 commented 1 month ago

If I've known the best configs after autotune, is there any way to save the dict of configurations so that I can load that directly in the next time? Using triton.heuristics can specify the meta data, but how to specify num_stages num_warps etc.?