Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom callbacks #595

Closed
alainjungo opened this issue Dec 5, 2019 · 4 comments
Closed

Custom callbacks #595

alainjungo opened this issue Dec 5, 2019 · 4 comments
Labels
feature Is an improvement or enhancement help wanted Open to be worked on

Comments

@alainjungo
Copy link

It would be great if the Trainer could support any custom callbacks that follow the Callback structure.

@alainjungo alainjungo added feature Is an improvement or enhancement help wanted Open to be worked on labels Dec 5, 2019
@jeffling
Copy link
Contributor

jeffling commented Dec 9, 2019

We've been talking about this for a while. I'm very for this.

One aspect I would like to add to this would be deterministic ordering of callbacks. It can be very difficult to maintain callbacks if the order of callback execution is not pre-defined, we end up having to handle a lot of edge cases for each callback as a result.

@jeremyjordan
Copy link
Contributor

jeremyjordan commented Feb 12, 2020

a very simple yet flexible way to achieve deterministic ordering is to use the order in which they're provided.

eg. Trainer(..., callbacks=[custom_callback_1, custom_callback_2, model_checkpoint_callback]) would first call custom_callback_1, then custom_callback_2, etc. for each hook

otherwise, enforcing order seems like a very daunting task.

see keras for an example.

@davidlrobinson
Copy link

As @jeremyjordan suggested, using a Keras-style ordered list of custom callbacks would be incredibly useful.

@Borda
Copy link
Member

Borda commented Feb 20, 2020

Yeah, after splitting callback in #849 we opened a discussion in #896...
@alainjungo do you have anything else you would add to this topic?
I would close this request in favour of #896 so pls let's continue the discussion there 🤖
btw @davidlrobinson do you remember the issue it was discussed so we can link it here too?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Is an improvement or enhancement help wanted Open to be worked on
Projects
None yet
Development

No branches or pull requests

5 participants