Closed brudfors closed 2 years ago
Looks good! For pretty printing what you could do is not save self.dropout = dropout
but only do self.activation = dropout
. And in the dropout class, you could have the pretty printing show the activation as well, e.g. Dropout(ReLU())
.
Good suggestion (y) I will try that
@balbasty your suggestion fixed the printing issue, want to merge?
Done! Thanks :)
@balbasty could you please tell me if you think this integration of Dropout into nitorch is okay?
I have added a dropout module, that is integrated into the conv class (see Line 833 in conv.py and Line 7 in dropout.py). I have a flag in the forward call of Dropout to ensure it is only applied during training. The only thing that is a bit messed up is the model printing:
because how I merge Dropout and the activation function.
The only model where I have included the dropout option is the regular CNN.