Skip to content

Commit f7bbd5a

Browse files
committed
Make N-dimensional dropout docstring clearer.
1 parent dd5d110 commit f7bbd5a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/layers/normalise.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ end
5151
5252
Dropout layer. In the forward pass, apply the [`Flux.dropout`](@ref) function on the input.
5353
54+
For N-D dropout layers (e.g. `Dropout2d` or `Dropout3d` in PyTorch),
55+
specify the `dims` keyword (i.e. `Dropout(p; dims = 2)` is a 2D dropout layer).
56+
5457
Does nothing to the input once [`Flux.testmode!`](@ref) is `true`.
5558
"""
5659
mutable struct Dropout{F,D}

0 commit comments

Comments
 (0)