Corrected test for asymmetric padding

This commit is contained in:
thebhatman 2019-06-11 20:20:00 +05:30
parent 94a2d1987d
commit f465665c73

View File

@ -25,8 +25,8 @@ end
@testset "asymmetric padding" begin
r = ones(Float32, 28, 28, 1, 1)
m = Conv((3, 3), 1=>1, relu; pad=(0,1,1,2))
m.weight.data[:] .= 1.0
m.bias.data[:] .= 0.0
m.weight[:] .= 1.0
m.bias[:] .= 0.0
y_hat = Flux.data(m(r))[:,:,1,1]
@test size(y_hat) == (27, 29)
@test y_hat[1, 1] 6.0