Skip to content

Commit 847efd2

Browse files
fix merge
1 parent 65c37c1 commit 847efd2

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/layers/basic.jl

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -119,11 +119,10 @@ end
119119

120120
@functor Dense
121121

122-
function (a::Dense)(x::AbstractVecOrMat)
122+
function (a::Dense)(x::AbstractArray)
123123
W, b, σ = a.W, a.b, a.σ
124-
# reshape to handle dims > 1 as batch dimensions
125124
sz = size(x)
126-
x = reshape(x, sz[1], :)
125+
x = reshape(x, sz[1], :) # reshape to handle dims > 1 as batch dimensions
127126
x = σ.(W*x .+ b)
128127
return reshape(x, :, sz[2:end]...)
129128
end

0 commit comments

Comments
 (0)