How to adjust dropout in your models

In response to a question, here’s how you can dynamically adjust the dropout level of your model while training. (Below is ResNet50 model).

Basically, you have to locate where the dropout layer is, and then reference it directly and adjust the .p (probability) variable to your desired value.

Note that the new XResNet doesn’t even use dropout, and recent work has shown that you are better off to use data augmentation instead of dropout…but the above is the quick way to adjust dropout :slight_smile:


For completeness, here’s an article I wrote regarding the paper showing data augmentation is better than dropout: