Hello.
I’d like to change my model’s attribute during training.
In order to that, now I’m calling my model as global variable.
For example:
trainer = create_supervised_trainer(~)

@trainer.on(Events.EPOCH_STARTED(once=10)
def change_attribute(engine):
    global model
    model.my_attribute = new_attribute

Is there more clear way using trainer?
I investigated trainer.__dict__ and trainer.state.__dict__, but there’s no attributes that keeps model.