Best way to add custom callbacks? #1954
-
I am a performance analyst and to get the most information possible, I need to instrument the code. I see that PyTorch provides callbacks at the train and step level (very coarse grain IMO), and that axolotl makes use of those for different purposes. The only way I have found now to add custom callbacks for my needs is to modify the |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Hey! This is actually one of the things that PR #1917 brings . It adds an example of adding a callback for the optimizer step level, but if you check the base class, there’s quite a few callback methods to override. If you take a look, it requires adding a file to the plugins directory then listing it in the yaml. |
Beta Was this translation helpful? Give feedback.
Hey! This is actually one of the things that PR #1917 brings . It adds an example of adding a callback for the optimizer step level, but if you check the base class, there’s quite a few callback methods to override.
If you take a look, it requires adding a file to the plugins directory then listing it in the yaml.