Question About Model Parameter Updates(self.training=false & requires_grad=true) #21329
Unanswered
D222097
asked this question in
Lightning Trainer API: Trainer, LightningModule, LightningDataModule
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
What will happen when self.vlm.training is set to False and self.vlm.parameters() has requires_grad set to True? Will the model parameters be updated if there is no dropout or batch normalization in the model?
Besides, I'm opening this issue due to an unexpected change in my model. The model includes self.dit, self.vlm, and other components. After completing self.train(), self.vlm.training is set to True, but when I enter training_step(), it switches to False. I'm not sure what is causing this behavior. Any suggestions regarding the potential reasons for this issue would be greatly appreciated.
Beta Was this translation helpful? Give feedback.
All reactions