Hi, is it possible to use PyTorch scheduler for triggering functions other than the optimizer ?
for example, here is a typical practice of schedulers
optimizer = torch.optim.SGD(model.parameters(), lr=0.1, momentum=0.9)
scheduler = ReduceLROnPlateau(optimizer, 'min')
for epoch in range(10):
    train(...)
     val_loss = validate(...)
     # Note that step should be called after validate()
    scheduler.step(val_loss)

but I want the best practice for having something like this:
optimizer = torch.optim.SGD(model.parameters(), lr=0.1, momentum=0.9)
scheduler = ReduceLROnPlateau(**my_func**, 'min')
for epoch in range(10):
    train(...)
     val_loss = validate(...)
     # Note that step should be called after validate()
    scheduler.step(val_loss)